title: NIghtwatch.js File Upload with Dropzone.js
body: <p>I am trying to upload a pdf file on our file upload using nightwatch.js but the thing is there are no input type="file" on our upload. The html looks like this:</p>
  
  <pre><code>&lt;form id="dropzone" action="/v2/asset/56013895934fd606006fb314" class="dropzone dz-clickable"&gt;
      &lt;div class="dz-clickable" id="dropzonePreview"&gt;
          &lt;i class="fa fa-cloud-upload main-icon initial-icon"&gt;&lt;/i&gt;
      &lt;/div&gt;
      &lt;div class="dz-default dz-message"&gt;
          &lt;span&gt;Drop a file here or click icon above to upload an image&lt;/span&gt;
      &lt;/div&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>I tried sending keys to the form, div and i but to no avail it wont work. This is my code on how i try upload the file:</p>
  
  <pre><code>var uploadInvoice = function(browser) {
      browser
          .waitForElementPresent(dashboardselector.view_assignment, 20000)
          .click(dashboardselector.view_assignment)
          .waitForElementVisible(".fa-plus", 20000)
          .click(".fa-plus")
          .click(".regionBillAsset &gt; div:nth-child(1) &gt; a:nth-child(1)")
          .setValue("#dropzone", require('path').resolve(__dirname+'/document.pdf'))
          .waitForElementVisible(".after-success", 20000)
          .click(".after-success")
  };
  </code></pre>
  
  <p>the upload starts on the setvalue part of my code. The upper part are just steps to go to the upload modal. Thanks in advance!!</p>
  
  <p><strong>UPDATE</strong>
  I have found a hidden input field on the html but even though I use setValue, it won't upload my file.</p>