mirror of
https://github.com/tursodatabase/libsql.git
synced 2025-05-29 15:23:00 +00:00
Merge pull request #1726 from tursodatabase/lucio/harden-ci-tests
tests: harden encryption tests
This commit is contained in:
2
.github/workflows/rust.yml
vendored
2
.github/workflows/rust.yml
vendored
@ -137,7 +137,7 @@ jobs:
|
||||
- name: clean build dir
|
||||
run: rm -rf libsql-ffi/bundled/SQLite3MultipleCiphers/build
|
||||
- name: embedded replica encryption tests
|
||||
run: cargo test -F test-encryption --package libsql-server --test tests embedded_replica
|
||||
run: cargo xtask test-encryption
|
||||
windows:
|
||||
runs-on: windows-latest
|
||||
name: Windows checks
|
||||
|
@ -18,6 +18,7 @@ fn try_main() -> Result<()> {
|
||||
Some("build-wasm") => build_wasm(&arg)?,
|
||||
Some("sim-tests") => sim_tests(&arg)?,
|
||||
Some("test") => run_tests(&arg)?,
|
||||
Some("test-encryption") => run_tests_encryption(&arg)?,
|
||||
Some("publish") => publish(&arg)?,
|
||||
_ => print_help(),
|
||||
}
|
||||
@ -32,6 +33,7 @@ build builds all languages
|
||||
build-wasm builds the wasm components in wasm32-unknown-unknown
|
||||
build-bundled builds sqlite3 and updates the bundeled code for ffi
|
||||
test runs the entire libsql test suite using nextest
|
||||
test-encryption runs encryption tests for embedded replicas
|
||||
sim-tests <test name> runs the libsql-server simulation test suite
|
||||
publish-cratesio publish libsql client crates to crates.io
|
||||
"
|
||||
@ -81,6 +83,26 @@ fn run_tests(arg: &str) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn run_tests_encryption(arg: &str) -> Result<()> {
|
||||
println!("installing nextest");
|
||||
run_cargo(&["install", "--force", "cargo-nextest"])?;
|
||||
println!("running nextest run");
|
||||
run_cargo(&[
|
||||
"nextest",
|
||||
"run",
|
||||
"-F",
|
||||
"test-encryption",
|
||||
"-p",
|
||||
"libsql-server",
|
||||
"--test",
|
||||
"tests",
|
||||
"embedded_replica",
|
||||
arg,
|
||||
])?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn sim_tests(arg: &str) -> Result<()> {
|
||||
run_cargo(&["test", "--test", "tests", arg])?;
|
||||
|
||||
|
Reference in New Issue
Block a user