Forum Discussion

otori's avatar
otori
New Contributor
6 years ago

Simulating file drop for windows desktop application

Hello Community,

 

our application accepts files by dropping them (e.g. from the windows file explorer) onto the application window.

We would like to test this feature, so I tried to implement a test that opens the windows explorer, navigates to a specific folder and drags a (prepared) file onto the application under test.

 

While this might work, this approach seems very unreliable:

The file explorer might change between windows updates, various versions and even different view options (details- vs symbol-view).

Additionally, the place where the explorer spawns is arbitrary and might overlap with our application (making a drag to our GUI impossible without moving the explorer first.)

These observations led to the conclusion, that the implementation as described above is not suitable.

 

Is there another more stable way to simulate a file drop on the application? (Preferably without using the windows explorer...)

 

Best regards,

Eugen

1 Reply

  • Marsha_R's avatar
    Marsha_R
    Champion Level 3

    If this feature was mine to test, I would leave it for the manual testing.  This feature isn't likely to change very often, so frequent regression testing isn't necessary.  All the outside influences you mentioned do make it difficult to automate, so spending the time on automation vs. an occasional manual test isn't a good investment.  Create some test download files to cover the cases, save those in a safe place, and use those each time for a quick manual test.