zipkin-instrumentation-cujojs-rest
Advanced tools
Comparing version 0.13.0 to 0.14.0
{ | ||
"name": "zipkin-instrumentation-cujojs-rest", | ||
"version": "0.13.0", | ||
"version": "0.14.0", | ||
"description": "Interceptor for instrumenting HTTP calls from the cujoJS rest library", | ||
@@ -19,4 +19,4 @@ "main": "lib/index.js", | ||
"rest": "^1.3.2", | ||
"zipkin": "^0.13.0" | ||
"zipkin": "^0.14.0" | ||
} | ||
} |
@@ -30,4 +30,6 @@ const {Tracer, ExplicitContext} = require('zipkin'); | ||
const port = server.address().port; | ||
const path = `http://127.0.0.1:${port}/abc`; | ||
client(path).then(successResponse => { | ||
const host = '127.0.0.1'; | ||
const urlPath = '/abc'; | ||
const url = `http://${host}:${port}${urlPath}`; | ||
client(url).then(successResponse => { | ||
const responseData = JSON.parse(successResponse.entity); | ||
@@ -51,4 +53,4 @@ server.close(); | ||
expect(annotations[2].annotation.annotationType).to.equal('BinaryAnnotation'); | ||
expect(annotations[2].annotation.key).to.equal('http.url'); | ||
expect(annotations[2].annotation.value).to.equal(path); | ||
expect(annotations[2].annotation.key).to.equal('http.path'); | ||
expect(annotations[2].annotation.value).to.equal(urlPath); | ||
@@ -55,0 +57,0 @@ expect(annotations[3].annotation.annotationType).to.equal('ClientSend'); |
6875
143