HtmlFileInput.isValid() is always evaluate to false while I see in debugger that files_ member has a file and setFiles() has been invoked. The message is the following:
[INFO] Form validation faild; element 'HtmlFileInput[<input id="image" type="file" style="box-shadow: none; border: 0px;" accept="image/png,image/jpeg" required="required" name="uploadedImage">]' was not valid. Submit cancelled.
So, either the change event doesn't set value attribute or HtmlFileInput should override isValid() method and look on files_ content.
Seen on htmlunit 2.36.0 and it worked to me on 2.21