Merge fix/SDK-7458-mocha-jasmine-test-tags - #221
Merged
bsautomation merged 3 commits intoSep 23, 2026
Merged
Conversation
WDIO Mocha and Jasmine never populated a test-level tags field, so every Observability test arrived with tags == []. Neither runner has a tag construct, so @tag tokens in the suite and test titles are the source -- the convention the node SDK already uses for Jest and Playwright. The leading @ is kept so these match the Cucumber runner's pickle tags. Both event paths were missing it: - Binary Flow: wdioMochaTestFramework#getTestData omitted KEY_TEST_TAGS. That 'test_tags' key was declared in the service's own constants and never written anywhere, while the binary has long consumed it (observability/languages/webdriverio/test-frameworks/mocha: tags = event.test_tags || []). Fixing only the Direct Flow would have left the CLI path -- the one App Automate runs -- still emitting []. - Direct Flow: insights-handler#getRunData built TestData with no tags key; tags were set only in the Cucumber-specific path. Inert for untagged suites: a title with no @ token yields [], so existing payloads are unchanged. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
- Tag pattern now requires the @ to start a token. /@[\w-]+/g matched any embedded @, so 'user@example.com' in a title produced a bogus @example tag and 'pkg@1.2.3' produced @1. Both now yield []. - Jasmine really is covered now. insights-handler#getRunData is reached only for mocha -- beforeTest and afterTest both early-return otherwise -- so jasmine events, and mocha skipped tests, go through reporter.ts#getRunData, which set scopes but no tags. It now sets tags too. Without this the Jasmine claim in the release notes was false. - Dropped the node-agent parity claim from the doc comment. That SDK strips the @ for Jest/Playwright (pwUtils.js), so the two emit different shapes; the @ is kept here to match this service's own Cucumber pickle tags, and the comment now says that instead. - Tests: added the embedded-@ cases and one case per hierarchy shape with scopes omitted, which exercises the getMochaTestHierarchy branch the previous suite never reached. Both orderings pinned to what the helper actually returns. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
bsautomation
requested review from
AakashHotchandani and
yashdsaraf
and removed request for
a team
September 23, 2026 13:20
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Central YAML (base), Organization UI (inherited), Workspace UI (inherited) Review profile: ASSERTIVE Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Merge into sdk_v9_pre_prod :by automationbs