domonic icon indicating copy to clipboard operation
domonic copied to clipboard

unit test and assertion for any existing or new method

Open byteface opened this issue 4 years ago • 1 comments

If you want to get involved then create an assertion in a unit test for any given method. some are still just print statements at the moment.

this may also uncover bugs. so be prepared.

or create a new unit test for a method that isn't done yet and make it work. good luck

byteface avatar Aug 14 '21 13:08 byteface

See Makefile to run all tests:

make test

NOTE - default tests ubuntu. so will fail on window when terminal test runs. comment out locally if that's the case

or to test a single function: python -m unittest tests.test_javascript.TestCase.test_javascript_array python -m unittest tests.test_dQuery.TestCase.test_addClass python -m unittest tests.test_geom.TestCase.test_vec2 python3 -m unittest tests.test_cmd.TestCase.test_cmd_dir # only windows

or to test a whole module: python -m unittest tests.test_html python -m unittest tests.test_CDN

to see coverage: coverage run -m unittest discover tests/ coverage report

byteface avatar Aug 14 '21 13:08 byteface