-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ENH] RecentFiles: Check for missing file in workflow dir #3064
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3064 +/- ##
==========================================
+ Coverage 82.35% 82.36% +0.01%
==========================================
Files 335 336 +1
Lines 58258 58289 +31
==========================================
+ Hits 47979 48011 +32
+ Misses 10279 10278 -1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While the travis tests pass (if you also fix one of the pylint warnings it will not complain and everything will be green),
appveyor errors out on your new unit test. Can you please check why windows have a problem with it.
56978e4
to
10b5db9
Compare
) | ||
search_paths = [("basedir", os.getcwd())] | ||
self.assertIsNotNone(recent_path.resolve(search_paths)) | ||
os.remove("test.tab") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like a classic trap of removing a file at the end, which might not happen if something goes wrong before the remove statement.
And here it is actually not that unusual since you have an assert above that might fail - try running this test on master.
I think there should be some utility functions for testing on temporary files somewhere... In any case some form of finally: cleanup
is needed and I suggest using python's TemporaryFiles too.
efda734
to
90ecf9a
Compare
b3f7b66
to
3928461
Compare
When opening saved workflow and file widget detects missing file, check if the file is placed in the same directory as workflow is saved.
Description of changes
When opening saved workflow and file widget detects missing file, check if the file is placed in the same directory as workflow is saved.
Includes