title: Issue with nosetests and file uploads
body: <p>I've been searching the web for the last two days trying to understand the problem I'm having with WebTest.  However, I have had no joy, and was wondering if anyone here might be able to help.</p>
  
  <p>I'm using nose to run test on a web application that I'm developing but seem to be having problems with a form that has a file upload field in it.  The form and validation works on the server when it is running normally, and if I run the test code from a shell it works as well.  However, whenever I run the test code from nose it fails to accept the submitted information.</p>
  
  <p>Here is an example of the form:</p>
  
  <pre><code>&lt;form method="POST" enctype="multipart/form-data" action="...."&gt;
      &lt;input type="text" name="first_name" id="first_name"&gt;
      &lt;input type="text" name="last_name" id="last_name"&gt;
      &lt;input type="file" name="thumbnail" id="thumbnail"&gt;
      &lt;input type="submit" value="Create" name="submit" id="submit"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>My WebTest code looks like this:</p>
  
  <pre><code>response = self.app.get( url(controller=self.controller, action='create') )
  form = response.form                                                       
  
  log.debug( form.submit_fields() )                                          
  
  form.set('first_name', 'test1-1')                                          
  form.set('last_name', 'test1-1')                                            
  form.set('thumbnail', '')                                                 
  
  log.debug( form.submit_fields() )                                          
  response = form.submit()
  </code></pre>
  
  <p>The response I get when I run this is that thumbnail is missing from the submitted values, even thought the field isn't required by the form validator.  When I compared the code output from Nose and when running it through a shell I noticed that the output from submit_fields was different</p>
  
  <p>Shell Output:</p>
  
  <pre><code>[('first_name', ''),('last_name', '')] #First log call
  [('first_name', 'test1-1'),('last_name', 'test1-1'), ('thumbnail', '')] #Second log call
  </code></pre>
  
  <p>Nose Output:</p>
  
  <pre><code>[(u'first_name', ''), (u'last_name', ''), (u'thumbnail', &lt;File name="thumbnail" id="thumbnail"&gt;)] #First log call
  [(u'first_name', 'test1-1'), (u'last_name', 'test1-1'),(u'thumbnail', &lt;File name="thumbnail" id="thumbnail"&gt;)] #Second log call
  </code></pre>
  
  <p>As you can see there is a difference in the shell doesn't have the thumbnail tuple, but sets it to a empty string which passes through without a problem.  However, in Nose there is already a tuple there and it doesn't reset the value.  Can anyone help me with this?  Is there a problem with trying multipart forms in WebTest when using the form.submit approach?</p>
  
  <p>Thanks in advance for your help.</p>
  
  <p>Library Information:
  Pylons-1.0.1
  WebTest-1.4.0
  WebOb-1.2.3
  nose-1.2.1</p>