Skip to content

Commit

Permalink
Do all CI builds with old rustc using shim crate
Browse files Browse the repository at this point in the history
Fixes the following error when testing against a compiler older
than 1.64:

    error: failed to select a version for the requirement `hashbrown = "^0.14"`
    candidate versions found which didn't match: 0.13.2, 0.13.1, 0.12.3, ...
    location searched: crates.io index
    required by package `indexmap v2.0.0`
        ... which satisfies dependency `indexmap = "^2"` of package `serde_json v1.0.97`
        ... which satisfies path dependency `serde_json` of package `serde_json_test v0.0.0`
  • Loading branch information
dtolnay committed Jun 24, 2023
1 parent d4c98d0 commit 706fc2b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,17 @@ jobs:
with:
toolchain: ${{matrix.rust}}
targets: ${{matrix.target}}
- run: cargo check
- run: cargo check --features float_roundtrip
- run: cargo check --features arbitrary_precision
- run: cargo check --features raw_value
- run: cargo check --features unbounded_depth
- run: cargo check --manifest-path tests/crate/Cargo.toml
- run: cargo check --manifest-path tests/crate/Cargo.toml --features float_roundtrip
- run: cargo check --manifest-path tests/crate/Cargo.toml --features arbitrary_precision
- run: cargo check --manifest-path tests/crate/Cargo.toml --features raw_value
- run: cargo check --manifest-path tests/crate/Cargo.toml --features unbounded_depth
- run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features --features alloc
- run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features --features alloc,arbitrary_precision
- run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features --features alloc,raw_value
- run: cargo check --features preserve_order
- run: cargo check --manifest-path tests/crate/Cargo.toml --features serde_json/preserve_order
if: matrix.rust != '1.56.1'
- run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features --features alloc,preserve_order
- run: cargo check --manifest-path tests/crate/Cargo.toml --no-default-features --features alloc,serde_json/preserve_order
if: matrix.rust != '1.56.1'
- name: Build without std
run: cargo check --manifest-path tests/crate/Cargo.toml --target ${{matrix.target}} --no-default-features --features alloc
Expand Down
1 change: 1 addition & 0 deletions tests/crate/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ default = ["std"]
std = ["serde_json/std"]
alloc = ["serde_json/alloc"]
#preserve_order = ["serde_json/preserve_order"]
float_roundtrip = ["serde_json/float_roundtrip"]
arbitrary_precision = ["serde_json/arbitrary_precision"]
raw_value = ["serde_json/raw_value"]
unbounded_depth = ["serde_json/unbounded_depth"]

0 comments on commit 706fc2b

Please sign in to comment.