-
Bug
-
Resolution: Fixed
-
Minor
-
2.7.3, 2.8.1
-
MOODLE_27_STABLE, MOODLE_28_STABLE
-
MOODLE_27_STABLE, MOODLE_28_STABLE
-
wip-mdl-48290
-
- Tail apache error log
- Run Behat with --tags @qformat
- Make sure you don't see any exception.
./question/format/xml/tests/behat/import_export.feature and
./question/format/gift/tests/behat/import_export.feature
use following_should_download_between_and_bytes(), which opens download popup though out the feature.
There are 2 potential problems:
- As selenium don't know how to deal with this window, we should avoid opening it. As this can lead to unwanted behaviour
- This is throwing error in apache error log
[Wed Nov 19 14:49:22.045768 2014] [:error] [pid 4392] [client 127.0.0.1:53922] Default exception handler: Can not find data record in database table context. Debug: SELECT * FROM {context} WHERE id = ?\n[array (\n 0 => 131000,\n)]\nError code: invalidrecord\n* line 1451 of /lib/dml/moodle_database.php: dml_missing_record_exception thrown\n* line 1427 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()\n* line 5360 of /lib/accesslib.php: call to moodle_database->get_record()\n* line 1433 of /lib/accesslib.php: call to context::instance_by_id()\n* line 3894 of /lib/filelib.php: call to get_context_info_array()\n* line 37 of /pluginfile.php: call to file_pluginfile()\n, referer: http://localhost/imaster/question/export.php
This happens as this is last step which gets executed and while this is happening, BeforeScenario event is fired and data is reset. Adding wait after pressing export or downloading step fix this problem, but we should try validate data (like in grade export), rather then checking if something is downloaded. Also, we should validate if data downloaded is valid data.
- is a regression caused by
-
MDL-47497 Behat steps for testing download
- Closed