Skip to content

Commit

Permalink
Run jaeger in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
MaeIsBad committed Feb 29, 2024
1 parent 84c46b4 commit b6b916b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
13 changes: 12 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,18 @@ jobs:
# Avoid duplicate jobs on PR from a branch on the same repo
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
services:
jaeger:
image: jaegertracing/all-in-one:1.35
env:
COLLECTOR_OTLP_ENABLED: "true"
COLLECTOR_OTLP_HTTP_HOST_PORT: 55681
ports:
- 16686:16686
- 55681:55681

steps:
- run: sudo echo "127.0.0.1 jaeger" | sudo tee -a /etc/hosts
- uses: actions/checkout@v4
- uses: Swatinem/rust-cache@v2
- uses: taiki-e/install-action@cargo-make
Expand All @@ -34,4 +45,4 @@ jobs:
- lint
- test
steps:
- run: ${{ !contains(needs.*.result, 'failure') }}
- run: ${{ !contains(needs.*.result, 'failure') }}
4 changes: 2 additions & 2 deletions tests/e2e/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ async fn get_spans(f: impl FnOnce()) -> Option<Vec<Span>> {
.as_millis();
let service_name = format!("e2e-test-{seed}");

let collector_url = "http://jaeger:55681";
let query_api_url = "http://jaeger:16685";
let collector_url = "http://127.0.0.1:55681";
let query_api_url = "http://127.0.0.1:16685";

let subscriber = configure_subscriber(
builder(&service_name)
Expand Down

0 comments on commit b6b916b

Please sign in to comment.