datacamp / sqlwhat

https://sqlwhat.readthedocs.io
GNU Affero General Public License v3.0
3 stars 8 forks source link

expose SCTs in cleaner fashion #105

Open machow opened 7 years ago

machow commented 7 years ago

We're doing this little song and dance right now.

from sqlwhat.checks.check_result import check_result, test_has_columns, test_nrows, test_ncols, test_column, allow_error, test_error, test_name_miscased, test_column_name
from sqlwhat.checks.check_logic import fail, multi, extend, test_or, test_correct
from sqlwhat.checks.check_funcs import check_node, check_field, test_student_typed, has_equal_ast, test_mc, success_msg, verify_ast_parses

Should be easier to just define a variable __all__ on each individual module

filipsch commented 7 years ago

I thinks it's beautiful ;) Very minor imo.

machow commented 7 years ago

The current form does have the advantage of making very clear where each SCT is coming from! We could always just have each import statement span multiple lines, rather than one super long one :p.