Hi All,
I am having a bit of problem running the lava_scheduler_app unit tests as per the instructions at
https://validation.linaro.org/static/docs/v2/dispatcher-testing.html. I keep getting errors such as the following:
$ sudo ./ci-run lava_scheduler_app.tests.test_device.TestTemplates.test_x86_template
+ set -e
+ getopts :pdty opt
+ shift 0
+ pep8 --ignore E501,E722 .
+ '[' -n '' ']'
+ echo 'Removing old .pyc files and cache'
Removing old .pyc files and cache
+ echo
+ find . -name '*.pyc' -delete
+ rm -rf ./.cache/
+ rm -rf ./__init__.py
+ echo 'Starting unit tests'
Starting unit tests
+ echo
+ '[' -z '' -a -z '' -a -z '' ']'
+ echo 'If it exists, a broken test database will be deleted without prompting.'
If it exists, a broken test database will be deleted without prompting.
+ python3 ./lava_server/manage.py test --noinput -v 2 lava_scheduler_app linaro_django_xmlrpc.tests lava_results_app
Traceback (most recent call last):
File "./lava_server/manage.py", line 78, in <module>
main()
File "./lava_server/manage.py", line 74, in main
execute_from_command_line(django_options)
File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 364, in execute_from_command_line
utility.execute()
File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 356, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/lib/python3/dist-packages/django/core/management/commands/test.py", line 29, in run_from_argv
super(Command, self).run_from_argv(argv)
File "/usr/lib/python3/dist-packages/django/core/management/base.py", line 283, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/lib/python3/dist-packages/django/core/management/base.py", line 330, in execute
output = self.handle(*args, **options)
File "/usr/lib/python3/dist-packages/django/core/management/commands/test.py", line 62, in handle
failures = test_runner.run_tests(test_labels)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 600, in run_tests
suite = self.build_suite(test_labels, extra_tests)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 526, in build_suite
suite = reorder_suite(suite, self.reorder_by, self.reverse)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 640, in reorder_suite
partition_suite_by_type(suite, classes, bins, reverse=reverse)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 663, in partition_suite_by_type
partition_suite_by_type(test, classes, bins, reverse=reverse)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 663, in partition_suite_by_type
partition_suite_by_type(test, classes, bins, reverse=reverse)
File "/usr/lib/python3/dist-packages/django/test/runner.py", line 667, in partition_suite_by_type
bins[i].add(test)
File "/usr/lib/python3/dist-packages/django/utils/datastructures.py", line 17, in add
self.dict[item] = None
TypeError: unhashable type: 'TestSchedulerAPI'
I have backed out all my changes and I still get the TypeErrors. I tried the latest in the master branch, and also the 2018.5 release tag. Could someone please let me know what I am doing incorrectly? Thanks!
Cheers,
Edmund
This message and any attachments may contain confidential information from Cypress or its subsidiaries. If it has been received in error, please advise the sender and immediately delete this message.