Skip to content
This repository has been archived by the owner on May 31, 2020. It is now read-only.

cricket-unittest fails to load tests #585

Closed
ghost opened this issue Jul 2, 2017 · 2 comments
Closed

cricket-unittest fails to load tests #585

ghost opened this issue Jul 2, 2017 · 2 comments

Comments

@ghost
Copy link

ghost commented Jul 2, 2017

Attempting to run cricket-unittest in the project's root directory, as per the docs, bails immediately with the following:

Traceback (most recent call last):
  File "/home/jms/.local/share/snakefarm/batavia-34/bin/cricket-unittest", line 11, in <module>
    sys.exit(main())
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/unittest/__main__.py", line 9, in main
    cricket_main(UnittestProject)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/main.py", line 74, in main
    project.refresh(test_list, errors)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/model.py", line 506, in refresh
    testModule._purge(timestamp)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/model.py", line 381, in _purge
    testModule._purge(timestamp)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/model.py", line 381, in _purge
    testModule._purge(timestamp)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/model.py", line 381, in _purge
    testModule._purge(timestamp)
  File "/home/jms/.local/share/snakefarm/batavia-34/lib/python3.4/site-packages/cricket/model.py", line 242, in _purge
    if testMethod.timestamp != timestamp:
AttributeError: 'TestCase' object has no attribute 'timestamp'

This looks to me like it could be a problem upstream with cricket, given that no batavia specific files are mentioned in the tb, but it could also have to do with how batavia's tests are formatted? I unfortunately don't know either project well enough to determine which project gets the bug report, so I'm submitting it here.

For what its worth, I'm on Arch Linux, and in three separate virtual environments (Python 3.4.6, 3.5.3, and 3.6.1) using cricket 0.2.5, I get the same traceback. IDLE and tk are properly installed. Running the tests via vanilla unittest or pytest both behave as expected. If I descend into the batavia build directory after running npm run build, cricket-unittest opens without error but (unsurprisingly) fails to load any tests.

@AlexLloyd0
Copy link
Contributor

This has also been raised as issue 39 on Cricket. It isn't specific to Batavia so discussion should probably be confined to there.

@ghost
Copy link
Author

ghost commented Jul 6, 2017

Ok my bad, I didn't find that issue over there. I'll close this one.

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant