6969 easy . stub ( :complete , nil ) do
7070 easy . perform
7171
72- _ ( span . name ) . must_equal 'HTTP'
72+ _ ( span . name ) . must_equal 'HTTP N/A '
7373 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
7474 _ ( span . attributes [ 'http.status_code' ] ) . must_be_nil
7575 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/test'
8787
8888 # NOTE: check the finished spans since we expect to have closed it
8989 span = exporter . finished_spans . first
90- _ ( span . name ) . must_equal 'HTTP'
90+ _ ( span . name ) . must_equal 'HTTP N/A '
9191 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
9292 _ ( span . attributes [ 'http.status_code' ] ) . must_be_nil
9393 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/test'
@@ -113,7 +113,7 @@ def stub_response(options)
113113
114114 it 'when response is successful' do
115115 stub_response ( response_code : 200 ) do
116- _ ( span . name ) . must_equal 'HTTP'
116+ _ ( span . name ) . must_equal 'HTTP N/A '
117117 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
118118 _ ( span . attributes [ 'http.status_code' ] ) . must_equal 200
119119 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/test'
@@ -126,7 +126,7 @@ def stub_response(options)
126126
127127 it 'when response is not successful' do
128128 stub_response ( response_code : 500 ) do
129- _ ( span . name ) . must_equal 'HTTP'
129+ _ ( span . name ) . must_equal 'HTTP N/A '
130130 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
131131 _ ( span . attributes [ 'http.status_code' ] ) . must_equal 500
132132 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/test'
@@ -139,9 +139,9 @@ def stub_response(options)
139139
140140 it 'when request times out' do
141141 stub_response ( response_code : 0 , return_code : :operation_timedout ) do
142- _ ( span . name ) . must_equal 'HTTP'
142+ _ ( span . name ) . must_equal 'HTTP N/A '
143143 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
144- _ ( span . attributes [ 'http.status_code' ] ) . must_be_nil
144+ _ ( span . attributes [ 'http.status_code' ] ) . must_equal 0
145145 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/test'
146146 _ ( span . status . code ) . must_equal (
147147 OpenTelemetry ::Trace ::Status ::ERROR
@@ -255,7 +255,7 @@ def stub_response(options)
255255
256256 stub_response ( response_code : 200 ) do
257257 _ ( exporter . finished_spans . size ) . must_equal 1
258- _ ( span . name ) . must_equal 'HTTP'
258+ _ ( span . name ) . must_equal 'HTTP N/A '
259259 _ ( span . attributes [ 'http.method' ] ) . must_equal '_OTHER'
260260 _ ( span . attributes [ 'http.url' ] ) . must_equal 'http://example.com/purge'
261261 end
0 commit comments