Hello, I’m testing a REST Java API using Postman and its command line tool Newman. Everything works fine when launching the tests from the command line. Now I’d like to integrate Newman to Travis and have Travis launch the tests during the build.
The problem is that the connection to localhost:8080 (where my API is supposed to be) is refused (see picture below)
Here is my travis config file :
language: java jdk: openjdk8 cache: directories: - $HOME/.m2 env: global: - CODECOV_TOKEN="XXXX" install: - cd p12-api - npm install newman services: - postgresql before_script: - node --version - npm --version - pwd - node_modules/.bin/newman --version - psql -c 'create database p12_demo;' -U postgres script: - mvn clean install -Pintegration-test - node_modules/.bin/newman run Tests_Postman/P12_Travis.postman_collection.json after_success: - bash <(curl -s https://codecov.io/bash)
What am I doing wrong? Any clues appreciated.