-
-
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] Widget testing utilities #1939
[ENH] Widget testing utilities #1939
Conversation
e675d5f
to
f0ddfb0
Compare
Current coverage is 89.31% (diff: 100%)@@ master #1939 diff @@
==========================================
Files 86 86
Lines 9119 9119
Methods 0 0
Messages 0 0
Branches 0 0
==========================================
Hits 8145 8145
Misses 974 974
Partials 0 0
|
One discrete constant class D with NaN values. | ||
|
||
Mixed continuous/discrete/string class metas ({X,D,S}M) | ||
One discrete constant class (D) with NaN values |
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.
duplicated line
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.
Lint also complains that there are some unused imports.
If the ones in try:except block are there for a reason, could you add a comment that clarifies that? Same goes for those, that are needed for doctests.
return os.path.join(dirname, filename) | ||
|
||
@classmethod | ||
def data_1(cls): |
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.
These methods could use more descriptive names. maybe missing_data_1? Telling what exactly is in the dataset would probably make them longer that 50 characters.
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.
I agree, but cant think of a naming scheme besides missing_data_{1,2,3}.
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.
So maybe just missing_data_n (with matching/modified filenames of the test files)?
I am afraid that otherwise the pattern will continue and we will get data_{4,5,6,7,8} in the future, making it impossible to tell what kind of data is used in the test.
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.
Ok
|
||
import numpy as np | ||
from AnyQt.QtWidgets import ( | ||
QApplication, QComboBox, QSpinBox, QDoubleSpinBox, QSlider | ||
) | ||
|
||
import Orange.data |
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.
Table is already imported in the line 15. Maybe the rest of the symbols could be imported in the same fashion?
77147bf
to
92fe2fb
Compare
Fix an error when a column contains (all/some) NaN values. Fixes biolabgh-1938
92fe2fb
to
76814cd
Compare
…-columns [ENH] Widget testing utilities (cherry picked from commit 40c677d) Conflicts: MANIFEST.in Orange/widgets/tests/base.py
Issue
Add some utilities for testing widgets, some datasets, ...
Also includes fix (and test) for gh-1938
Description of changes
Includes