Error while running single BokChoy acceptance test case.

13 views
Skip to first unread message

Pravin Chavre

unread,
May 4, 2018, 2:13:53 AM5/4/18
to General Open edX discussion
Hello!
I am trying to run a single BokChoy acceptance test using instructions given here: https://github.com/edx/edx-platform/blob/master/docs/testing.rst

It says:
"To execute only a certain test case, specify the file name, class, and test case method:
paver test_bokchoy -t lms/test_lms.py::RegistrationTest::test_register
"

I tried to run the test_all_sections_and_fields_are_present test case using the above command as follows.

paver test_bokchoy -t lms/test_account_settings.py::AccountSettingsPageTest::test_all_sections_and_fields_are_present

This gave an error as follows:
----------------
Confirming servers have started...
Checking server 0.0.0.0 on port 8003
Checking server 0.0.0.0 on port 8031
Installing course fixture for forums
DEFAULT_STORE=split SCREENSHOT_DIR='/edx/app/edxapp/edx-platform/test_root/log' BOK_CHOY_HAR_DIR='/edx/app/edxapp/edx-platform/test_root/log/hars' BOKCHOY_A11Y_CUSTOM_RULES_FILE='/edx/app/edxapp/edx-platform/node_modules/edx-custom-a11y-rules/lib/custom_a11y_rules.js' SELENIUM_DRIVER_LOG_DIR='/edx/app/edxapp/edx-platform/test_root/log' VERIFY_XSS='False' nosetests /edx/app/edxapp/edx-platform/common/test/acceptance/tests/lms/test_account_settings.py::AccountSettingsPageTest::test_all_sections_and_fields_are_present --xunit-file=/edx/app/edxapp/edx-platform/reports/bok_choy/xunit.xml --verbosity=2
========================================
 Running tests for bok-choy
========================================
Traceback (most recent call last):
  File "/edx/app/edxapp/venvs/edxapp/bin/nosetests", line 11, in <module>
    sys.exit(run_exit())
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/core.py", line 121, in __init__
    **extra_args)
  File "/usr/lib/python2.7/unittest/main.py", line 94, in __init__
    self.parseArgs(argv)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/core.py", line 179, in parseArgs
    self.createTests()
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/core.py", line 193, in createTests
    self.test = self.testLoader.loadTestsFromNames(self.testNames)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/loader.py", line 481, in loadTestsFromNames
    return unittest.TestLoader.loadTestsFromNames(self, names, module)
  File "/usr/lib/python2.7/unittest/loader.py", line 130, in loadTestsFromNames
    suites = [self.loadTestsFromName(name, module) for name in names]
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/loader.py", line 378, in loadTestsFromName
    addr = TestAddress(name, workingDir=self.workingDir)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/selector.py", line 226, in __init__
    self.filename, self.module, self.call = split_test_name(name)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/nose/util.py", line 380, in split_test_name
    file_part, fn = tail.split(':')
ValueError: too many values to unpack

Cleaning up after bok-choy
Cleaning up databases...
./manage.py lms --settings bok_choy flush --traceback --noinput
---> pavelib.utils.test.bokchoy_utils.clear_mongo
mongo test --eval 'db.dropDatabase()' > /dev/null


================================================
Tests failed in the following suites:
* bok-choy


Please tell how to successfully run a single BokChoy acceptance testcase.

Reply all
Reply to author
Forward
0 new messages