AWS Amplify ci/cd hangs at test stage

Viewed 145

I have my amplify project connected to gitlab And added this segment to run API Jest tests:

test:
  phases:
    preTest:
      commands:
       - npm install
    test:
      commands:
        - npm test

But the test section became and stays as "pending"

In logs I see only the following:

                                 # Starting phase: preTest
                                 # Executing command: npm install
2020-10-28T05:58:39.496Z [WARNING]: npm

Can anyone help with this?

1 Answers

Running test in watch mode solved the problem:

npm test -- --watchAll=false
Related