Skip to content

Commit

Permalink
Bump toolchain to 1.76.0
Browse files Browse the repository at this point in the history
We also need to fix the sqlite-bundled job to the yesterday nightly due
to rust-lang/rust#120830
  • Loading branch information
weiznich committed Feb 9, 2024
1 parent dfeec4b commit 1e78a88
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 7 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -420,29 +420,30 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2024-02-08
components: "rust-src"
- name: Cache cargo registry
uses: Swatinem/rust-cache@v2
with:
key: sqlite_bundled-cargo-${{ hashFiles('**/Cargo.toml') }}

- name: Test diesel-cli
run: cargo +nightly test --manifest-path diesel_cli/Cargo.toml --no-default-features --features "sqlite-bundled"
run: cargo +${{steps.toolchain.outputs.name} test --manifest-path diesel_cli/Cargo.toml --no-default-features --features "sqlite-bundled"

- name: Run diesel_tests with ASAN enabled
env:
RUSTFLAGS: -Zsanitizer=address
ASAN_OPTIONS: detect_stack_use_after_return=1
run: cargo +nightly -Z build-std test --manifest-path diesel_tests/Cargo.toml --no-default-features --features "sqlite libsqlite3-sys libsqlite3-sys/bundled libsqlite3-sys/with-asan" --target x86_64-unknown-linux-gnu
run: cargo +${{steps.toolchain.outputs.name} -Z build-std test --manifest-path diesel_tests/Cargo.toml --no-default-features --features "sqlite libsqlite3-sys libsqlite3-sys/bundled libsqlite3-sys/with-asan" --target x86_64-unknown-linux-gnu

- name: Run diesel tests with ASAN enabled
env:
RUSTDOCFLAGS: -Zsanitizer=address
RUSTFLAGS: -Zsanitizer=address
ASAN_OPTIONS: detect_stack_use_after_return=1
run: cargo +nightly -Z build-std test --manifest-path diesel/Cargo.toml --no-default-features --features "sqlite extras libsqlite3-sys libsqlite3-sys/bundled libsqlite3-sys/with-asan" --target x86_64-unknown-linux-gnu
run: cargo +${{steps.toolchain.outputs.name} -Z build-std test --manifest-path diesel/Cargo.toml --no-default-features --features "sqlite extras libsqlite3-sys libsqlite3-sys/bundled libsqlite3-sys/with-asan" --target x86_64-unknown-linux-gnu

minimal_rust_version:
name: Check Minimal supported rust version (1.70.0)
Expand Down
8 changes: 6 additions & 2 deletions diesel/src/pg/types/json.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,13 @@ impl ToSql<sql_types::Jsonb, Pg> for serde_json::Value {
}
}

#[cfg(tests)]
#[cfg(test)]
mod tests {
use crate::query_builder::bind_types::ByteWrapper;
use crate::deserialize::FromSql;
use crate::pg::{Pg, PgValue};
use crate::query_builder::bind_collector::ByteWrapper;
use crate::serialize::{Output, ToSql};
use crate::sql_types;

#[test]
fn json_to_sql() {
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.75.0
1.76.0

0 comments on commit 1e78a88

Please sign in to comment.