Skip to content

fix(headless-chrome): ignore manual connect_to_url in CI #16

fix(headless-chrome): ignore manual connect_to_url in CI

fix(headless-chrome): ignore manual connect_to_url in CI #16

Workflow file for this run

name: CI
on:
push:
branches:
- "**"
pull_request:
workflow_dispatch:
permissions:
contents: read
env:
CARGO_TERM_COLOR: always
RUST_BACKTRACE: 1
jobs:
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Cargo fmt
run: cargo fmt --all -- --check
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
- name: Cargo clippy
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
test:
runs-on: ubuntu-latest
# Hermetic httpbin for HTTP-semantics integration tests. Plain HTTP loopback avoids
# public-egress flakiness that previously broke http_fetch / redirects / non_html suites.
services:
httpbin:
# Classic Python httpbin: full endpoint set including /brotli and authenticated{true}
# shape used by HTTP-semantics tests. Plain HTTP loopback keeps the suite hermetic.
image: kennethreitz/httpbin:latest
ports:
- 8080:80
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Wait for hermetic httpbin
run: |
for i in $(seq 1 60); do
if curl -fsS -o /dev/null -w "%{http_code}" "http://127.0.0.1:8080/get" | grep -q '^200$'; then
echo "httpbin ready"
exit 0
fi
sleep 1
done
echo "hermetic httpbin did not become ready" >&2
exit 1
- name: Cargo test
run: cargo test --workspace --all-features
env:
RUST_TEST_THREADS: "1"
BASECRAWL_HTTPBIN_BASE: http://127.0.0.1:8080