diff --git a/.config/nextest.toml b/.config/nextest.toml index bb608243..37b7ae13 100644 --- a/.config/nextest.toml +++ b/.config/nextest.toml @@ -1,3 +1,5 @@ +serial-integration = { max-threads = 1 } + [profile.default] fail-fast = true failure-output = "immediate-final" @@ -9,5 +11,10 @@ fail-fast = false failure-output = "immediate-final" slow-timeout = { period = "60s", terminate-after = 2 } +[[profile.ci.overrides]] +filter = 'package(integration-tests)' +test-group = 'serial-integration' +slow-timeout = { period = "120s" } + [profile.ci.junit] path = "junit.xml" diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 615a9785..f5249afc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,4 +44,4 @@ jobs: cache-on-failure: true - name: Test with latest nextest release - run: cargo nextest run --workspace --target ${{ matrix.target }} \ No newline at end of file + run: cargo nextest run --profile ci --workspace --target ${{ matrix.target }} \ No newline at end of file diff --git a/crates/corrosion/src/command/consul/sync.rs b/crates/corrosion/src/command/consul/sync.rs index e370aa65..e1359c4e 100644 --- a/crates/corrosion/src/command/consul/sync.rs +++ b/crates/corrosion/src/command/consul/sync.rs @@ -148,18 +148,18 @@ async fn setup( let col_infos: Vec = conn.prepare("PRAGMA table_info(consul_services)")?.query_map([], |row| Ok(ColumnInfo { name: row.get(1)?, kind: row.get(2)? })).map_err(|e| eyre::eyre!("could not query consul_services' table_info: {e}"))?.collect::, _>>()?; let expected_cols = [ - ("node", ColumnType::Text), - ("id", ColumnType::Text), - ("name", ColumnType::Text), - ("tags", ColumnType::Text), - ("meta", ColumnType::Text), - ("port", ColumnType::Integer), - ("address", ColumnType::Text), - ("updated_at", ColumnType::Integer), + ("node", vec![ColumnType::Text]), + ("id", vec![ColumnType::Text]), + ("name", vec![ColumnType::Text]), + ("tags", vec![ColumnType::Text, ColumnType::Blob]), + ("meta", vec![ColumnType::Text, ColumnType::Blob]), + ("port", vec![ColumnType::Integer]), + ("address", vec![ColumnType::Text]), + ("updated_at", vec![ColumnType::Integer]), ]; for (name, kind) in expected_cols { - if col_infos.iter().find(|info| info.name == name && info.kind == kind ).is_none() { + if col_infos.iter().find(|info| info.name == name && kind.contains(&info.kind) ).is_none() { eyre::bail!("expected a column consul_services.{name} w/ type {kind:?}"); } } @@ -167,18 +167,18 @@ async fn setup( let col_infos: Vec = conn.prepare("PRAGMA table_info(consul_checks)")?.query_map([], |row| Ok(ColumnInfo { name: row.get(1)?, kind: row.get(2)? })).map_err(|e| eyre::eyre!("could not query consul_checks' table_info: {e}"))?.collect::, _>>()?; let expected_cols = [ - ("node", ColumnType::Text), - ("id", ColumnType::Text), - ("service_id", ColumnType::Text), - ("service_name", ColumnType::Text), - ("name", ColumnType::Text), - ("status", ColumnType::Text), - ("output", ColumnType::Text), - ("updated_at", ColumnType::Integer), + ("node", vec![ColumnType::Text]), + ("id", vec![ColumnType::Text]), + ("service_id", vec![ColumnType::Text]), + ("service_name", vec![ColumnType::Text]), + ("name", vec![ColumnType::Text]), + ("status", vec![ColumnType::Text]), + ("output", vec![ColumnType::Text]), + ("updated_at", vec![ColumnType::Integer]), ]; for (name, kind) in expected_cols { - if col_infos.iter().find(|info| info.name == name && info.kind == kind ).is_none() { + if col_infos.iter().find(|info| info.name == name && kind.contains(&info.kind) ).is_none() { eyre::bail!("expected a column consul_checks.{name} w/ type {kind:?}"); } }