-
Notifications
You must be signed in to change notification settings - Fork 806
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
improv(instrumentation-http): supressInstrumentation when we get a request on ignoredPath [#1831] #1838
improv(instrumentation-http): supressInstrumentation when we get a request on ignoredPath [#1831] #1838
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1838 +/- ##
==========================================
- Coverage 92.60% 92.41% -0.20%
==========================================
Files 174 170 -4
Lines 6048 5734 -314
Branches 1288 1236 -52
==========================================
- Hits 5601 5299 -302
+ Misses 447 435 -12
|
Maybe a simple regression test should be added to ensure that this doesn't get removed per accident. |
That's why i added https://github.com/open-telemetry/opentelemetry-js/pull/1838/files#diff-ce862d1183e8ab52e6c94e5cc3022280fe213394a9b88e7f473f16620db344efR213, it create a "child" span within the request so if |
df17763
to
1c2ab82
Compare
I think added changes are not covered with unit tests. |
It is tested here https://github.com/open-telemetry/opentelemetry-js/pull/1838/files#diff-ce862d1183e8ab52e6c94e5cc3022280fe213394a9b88e7f473f16620db344efR213. Without this change, that change to the test would cause it to fail because it creates a span that would not be ignored as a child of an ignored path. |
I would expect some simple test with checking that the span hasn't been exported, hard to say where is such unit test something like this No unit test has been added, just modification of |
I don't agree, no unit test has been added because a test for the feature that the improv is on (when we ignore paths in the config) was already existing. I don't see the advantage of having multiple individual test for the same feature instead of one that test everything.
That's generally a "problem" with the tests we write, there are no description of each |
That is exactly what I'm telling, having a simple unit test as I described would be a perfect description and documentation of the changed piece of code. This is a 5 minute and will save much more minutes in future for any1 who will be modifying this part of code. Unit test will fail and it will tell you exactly why. |
I think you misundestood what i said, i meant that it's much better to document what |
…en-telemetry#1838) * test: fix TAV tests for @cucumber/cucumber and @aws-sdk/client-s3 - Switch to 'npm run --ws test-all-versions ...' for running TAV tests, instead of 'lerna run test-all-versions ...' because nx sets 'npm_config_legacy_peer_deps=true' which breaks '@cucumber/cucumber@9.1.2' install and could break other installs by ignoring 'peerDependencies'. - Skip the bad '@aws-sdk/client-s3@3.377.0' release in TAV tests. Also: - Reduce the number of versions of 'aws-sdk' and '@aws-sdk/*' packages test in TAV tests from 249, 143, and 132 versions currently, to 7 each. - Add a top-level `npm run test-all-versions` script to run that script in all packages that have one. This is the equivalent of the "test-all-versions.yml" CI workflow. Fixes: open-telemetry#1828
Fixes #1831