Wunderbyte-GmbH / moodle-payment_gw_mpay24

Implements Mpay24 as a moodle payment gateway
0 stars 1 forks source link

PHPUnit Test fails: checkout_test::test_checkout #2

Open bernhard-wunderbyte opened 6 days ago

bernhard-wunderbyte commented 6 days ago

There was 1 error:

1) paygw_mpay24\checkout_test::test_checkout InvalidArgumentException: The merchant ID '' you have given is wrong, it must be 5-digit number and starts with 7 or 9!

/home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/payment/gateway/mpay24/thirdparty/mpay24/src/Mpay24Config.php:167 /home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/payment/gateway/mpay24/thirdparty/mpay24/src/Mpay24Config.php:133 /home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/payment/gateway/mpay24/thirdparty/mpay24/src/Mpay24.php:37 /home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/payment/gateway/mpay24/classes/external/get_config_for_js.php:134 /home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/payment/gateway/mpay24/tests/checkout_test.php:138 /home/runner/work/moodle-payment_gw_mpay24/moodle-payment_gw_mpay24/moodle/lib/phpunit/classes/advanced_testcase.php:81

semteacher commented 4 days ago

@georgmaisser @bernhard-wunderbyte

  1. During local tests both phpunit and behat passed OK
  2. Under my repo all steps passed OK except backward redirect (disabled now): https://github.com/semteacher/moodle-payment_gw_mpay24/actions/runs/11969473949. Besides, even in that cases - user being redirected back and respose processed properly: MPay24-basic-configuration-and-useage-by-user_I-wait-to-be-redirected_70 Screen is from GitHub - I have empleyed actions/upload-artifact@v4 to retreive it. So all is OK except some JS or crashed or unresponsible. But it is necessary to catch bronsers console / network dump somehow from github. And I do not know how to achieve it now.
  3. Finally - does repository secrets had been added there? Text of the error " The merchant ID '' you have given is wrong, it must be 5-digit number and starts with 7 or 9!" pointing that it did not.
bernhard-wunderbyte commented 4 days ago

@georgmaisser How should we proceed?

georgmaisser commented 4 days ago

I added secrets and retriggered this job: test (8.1, MOODLE_405_STABLE, mariadb)

Let's see if it works with the secrets

semteacher commented 4 days ago

@georgmaisser Still failed. My fork passed https://github.com/semteacher/moodle-payment_gw_mpay24/actions/runs/11969473949 Have you used correct variable names (and its values): image