Skip to content

Commit

Permalink
run e2e tests over https
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Skinner committed Nov 25, 2024
1 parent 7317071 commit 26731a5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ function Navigation() {
<div>
<nav>
<li>
<Link to="home">Home</Link>
<Link to="/docs/route-change-spans">Home</Link>
</li>
<li>
<Link to="new-route" id="change-route">Change Route</Link>
<Link to="/new-route" id="change-route">Change Route</Link>
</li>
</nav>
</div>
Expand All @@ -24,13 +24,13 @@ function Navigation() {

function App() {
return (
<Router basename="/docs/route-change-spans/">
<Router>
<Navigation />
<Switch>
<Route path="home">
<Route path="/docs/route-change-spans">
<Home />
</Route>
<Route path="new-route">
<Route path="/new-route">
<About />
</Route>
</Switch>
Expand Down
6 changes: 3 additions & 3 deletions test/browser/features/route-change-spans.feature
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ Feature: Route change spans
And I click the element "change-route"
When I wait to receive 1 trace

Then every span string attribute "bugsnag.browser.page.url" matches the regex "^http(s)?:\/\/.*:[0-9]{4}\/docs\/route-change-spans/new-route$"
Then every span string attribute "bugsnag.browser.page.url" matches the regex "^http(s)?:\/\/.*:[0-9]{4}\/new-route$"
And a span named "[RouteChange]/new-route" contains the attributes:
| attribute | type | value |
| bugsnag.span.category | stringValue | route_change |
| bugsnag.browser.page.title | stringValue | New Route |
| bugsnag.browser.page.route | stringValue | /docs/route-change-spans/new-route |
| bugsnag.browser.page.route | stringValue | /new-route |
| bugsnag.browser.page.previous_route | stringValue | /docs/route-change-spans/ |
| bugsnag.browser.page.route_change.trigger | stringValue | pushState |

Expand All @@ -20,7 +20,7 @@ Feature: Route change spans
When I wait to receive 1 trace

Then every span string attribute "bugsnag.browser.page.url" matches the regex "^http(s)?:\/\/.*:[0-9]{4}\/docs\/route-change-spans(\/)?\?endpoint=.*\&logs=.*\&api_key=.*#anchor-link$"
Then a span named "[RouteChange]/route-change-spans/" contains the attributes:
Then a span named "[RouteChange]/docs/route-change-spans/" contains the attributes:
| attribute | type | value |
| bugsnag.span.category | stringValue | route_change |
| bugsnag.browser.page.title | stringValue | Route change spans |
Expand Down

0 comments on commit 26731a5

Please sign in to comment.