Skip to content

MFTF Standalone, difficulties running tests on remote

Someone please correct me if I am mistaken in my assumption that MFTF standalone can be used to run tests on remote environments, given the correct credentials. Currently, I have a working Magento 2.4.5-p1 installation with a working MFTF set up. I may have missed it in the docs, but if I wanted to run, say, the AdminLoginTest on one Magento AWS instance from another AWS instance hosting the MFTF, I would need to:

  1. Install and set up/configure Magento 2 and MFTF
  2. Ensure that MFTF and the target server (to be tested by the standalone instance) are in the same IP restriction group – that they are able to communicate with each other. I have verified this with curl.
  3. Edit the files dev/tests/acceptance/.env and dev/tests/acceptance/.credentials with their respective accurate information, e.g. URI, Admin path, Admin username in .env, password in .credentials
  4. confirm that the java selenium server is running (mine’s on port 4444)
  5. I would now expect that running a generated test, such as AdminLoginTest as the appropriate user would yield a running test with results, like so: vendor/bin/mftf run:test AdminLoginTest

So far so good? What I get is "Suite Data Parser Error: Cannot retrieve API token with credentials. : Error HTTP response code: 401 Response:{"message":"The account sign-in was incorrect or your account is disabled temporarily."}"

I have confirmed that the login information is accurate, even going so far as to change the passwords to simpler, insecure versions in the hope that the test would run. Can anyone help me understand what I’m doing wrong?