-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Closed
Labels
Component: CronFixed in 2.1.xThe issue has been fixed in 2.1 release lineThe issue has been fixed in 2.1 release lineFixed in 2.2.xThe issue has been fixed in 2.2 release lineThe issue has been fixed in 2.2 release lineFixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseThe issue has been reproduced on latest 2.2 release
Description
Preconditions
- Magento 2.2.3 installation
- Integration test database set up
Steps to reproduce
- Remove config fixture from ProcessCronQueueObserverTest::testDispatchScheduled
- In dev/tests/integration run
../../../vendor/bin/phpunit testsuite/Magento/Cron/Observer/ProcessCronQueueObserverTest.php
Expected result
- testDispatchScheduled fails
Actual result
- testDispatchScheduled passes
Additional notes
magento2/dev/tests/integration/testsuite/Magento/Cron/Observer/ProcessCronQueueObserverTest.php
Line 30 in a328a6b
| * @magentoConfigFixture current_store crontab/default/jobs/catalog_product_alert/schedule/cron_expr 8 * * * * |
The integration tests succeeds regardless if the config fixture is there or not.
It seems like the fixture should be removed, if it has no effect on the result of the test.
On the other hand the test should perhaps filter the collection by the job code of the configured cron like below:
$collection->addFieldToFilter('job_code', 'catalog_product_alert');
When this is added to the test, it fails, so I'm not quite sure if that is correct.
Metadata
Metadata
Assignees
Labels
Component: CronFixed in 2.1.xThe issue has been fixed in 2.1 release lineThe issue has been fixed in 2.1 release lineFixed in 2.2.xThe issue has been fixed in 2.2 release lineThe issue has been fixed in 2.2 release lineFixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseThe issue has been reproduced on latest 2.2 release