diff --git a/.travis.yml b/.travis.yml index e2d82f1..8cb6e12 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,8 +7,12 @@ script: branches: only: - master +services: + - docker before_install: - export CHROME_BIN=chromium-browser + - docker pull eclipse-mosquitto + - docker run -d -p 9001:9001 -v $(pwd)/mosquitto.conf:/mosquitto/config/mosquitto.conf:ro eclipse-mosquitto before_script: - export DISPLAY=:99.0 diff --git a/mosquitto.conf b/mosquitto.conf new file mode 100644 index 0000000..5a60f49 --- /dev/null +++ b/mosquitto.conf @@ -0,0 +1,6 @@ +listener 9001 +protocol websockets + +persistence true +persistence_location /mosquitto/data/ +log_dest file /mosquitto/log/mosquitto.log \ No newline at end of file diff --git a/tests/mqtt.service.spec.ts b/tests/mqtt.service.spec.ts index d52e479..8cb0eb3 100644 --- a/tests/mqtt.service.spec.ts +++ b/tests/mqtt.service.spec.ts @@ -17,8 +17,8 @@ import { const config: IMqttServiceOptions = { connectOnCreate: true, - hostname: 'test.mosquitto.org', - port: 8080, + hostname: 'localhost', + port: 9001, path: '' };