Skip to content

Commit 0e8950d

Browse files
authored
Add serial-test for unit testing (#34)
1 parent 1e76c91 commit 0e8950d

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

server/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ zip = { git = "https://github.com/zip-rs/zip" }
5959
[dev-dependencies]
6060
maplit = "1.0.2"
6161
rstest = "0.15.0"
62+
serial_test = { version = "0.9.0", default-features = false }
6263

6364
[package.metadata.parseable_ui]
6465
assets-url = "https://github.com/parseablehq/frontend/releases/download/v0.0.1/build.zip"

server/src/metadata.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ mod tests {
181181
use super::*;
182182
use maplit::hashmap;
183183
use rstest::*;
184+
use serial_test::serial;
184185

185186
#[rstest]
186187
#[case::zero(0, 0, 0)]
@@ -226,6 +227,7 @@ mod tests {
226227
#[rstest]
227228
#[case::stream_schema_alert("teststream", "schema", "alert_config")]
228229
#[case::stream_only("teststream", "", "")]
230+
#[serial]
229231
fn test_add_stream(
230232
#[case] stream_name: String,
231233
#[case] schema: String,
@@ -249,6 +251,7 @@ mod tests {
249251

250252
#[rstest]
251253
#[case::stream_only("teststream")]
254+
#[serial]
252255
fn test_delete_stream(#[case] stream_name: String) {
253256
clear_map();
254257
STREAM_INFO

0 commit comments

Comments
 (0)