Skip to content

Integration test ProcessCronQueueObserverTest.php succeeds regardless of magento config fixture #16243

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
evktalo opened this issue Jun 19, 2018 · 5 comments
Labels
Component: Cron Fixed in 2.1.x The issue has been fixed in 2.1 release line Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release

Comments

@evktalo
Copy link
Contributor

evktalo commented Jun 19, 2018

Preconditions

  1. Magento 2.2.3 installation
  2. Integration test database set up

Steps to reproduce

  1. Remove config fixture from ProcessCronQueueObserverTest::testDispatchScheduled
  2. In dev/tests/integration run
    ../../../vendor/bin/phpunit testsuite/Magento/Cron/Observer/ProcessCronQueueObserverTest.php

Expected result

  1. testDispatchScheduled fails

Actual result

  1. testDispatchScheduled passes

Additional notes

* @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.

@magento-engcom-team magento-engcom-team added the Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed label Jun 19, 2018
@kkrieger85
Copy link

Hi @evktalo please pay attention to Issue reporting Guidelines and Issue Template

@magento-engcom-team magento-engcom-team added Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed and removed Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed labels Jun 19, 2018
@VladimirZaets
Copy link
Contributor

Hi @evktalo. Thank you for your report.
The issue has been fixed in #16253 by @evktalo in 2.3-develop branch
Related commit(s):

The fix will be available with the upcoming 2.3.0 release.

@VladimirZaets VladimirZaets added the Fixed in 2.3.x The issue has been fixed in 2.3 release line label Jul 2, 2018
@ghost ghost self-assigned this Jul 26, 2018
@ghost ghost added Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Component: Cron labels Jul 26, 2018
@ghost
Copy link

ghost commented Jul 26, 2018

@evktalo, thank you for your report.
We've acknowledged the issue and added to our backlog.

@ghost ghost removed their assignment Jul 26, 2018
@ghost ghost added the Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development label Jul 26, 2018
@sidolov sidolov added the Fixed in 2.1.x The issue has been fixed in 2.1 release line label Aug 1, 2018
@sidolov
Copy link
Contributor

sidolov commented Aug 1, 2018

Hi @evktalo. Thank you for your report.
The issue has been fixed in #17192 by @gelanivishal in 2.1-develop branch
Related commit(s):

The fix will be available with the upcoming 2.1.15 release.

@sidolov
Copy link
Contributor

sidolov commented Aug 2, 2018

Hi @evktalo. Thank you for your report.
The issue has been fixed in #17191 by @gelanivishal in 2.2-develop branch
Related commit(s):

The fix will be available with the upcoming 2.2.7 release.

@sidolov sidolov added the Fixed in 2.2.x The issue has been fixed in 2.2 release line label Aug 2, 2018
@sidolov sidolov closed this as completed Aug 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Cron Fixed in 2.1.x The issue has been fixed in 2.1 release line Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release
Projects
None yet
Development

No branches or pull requests

5 participants