diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 0157c230edc..697aa7ee9e5 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -144,6 +144,9 @@ jobs: - uses: actions/setup-node@v4 with: node-version: '20' + - uses: denoland/setup-deno@v1 + with: + deno-version: v1.x - run: cargo test - run: cargo test -p wasm-bindgen-cli-support - run: cargo test -p wasm-bindgen-cli diff --git a/Cargo.toml b/Cargo.toml index c06934617d1..d7d1c50f2b3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -55,6 +55,15 @@ serde_derive = "1.0" wasm-bindgen-test-crate-a = { path = 'tests/crates/a', version = '0.1' } wasm-bindgen-test-crate-b = { path = 'tests/crates/b', version = '0.1' } +[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] +assert_cmd = "1.0" +lazy_static = "1.4.0" +predicates = "1.0.0" +rand = "0.8.5" +regex = "1.10.4" + +[dev-dependencies] + [workspace] members = [ "benchmarks", diff --git a/crates/cli-support/src/js/mod.rs b/crates/cli-support/src/js/mod.rs index 8c270186bf7..a8e242e0d6a 100644 --- a/crates/cli-support/src/js/mod.rs +++ b/crates/cli-support/src/js/mod.rs @@ -345,7 +345,8 @@ impl<'a> Context<'a> { }} const wasmInstance = (await WebAssembly.instantiate(wasmCode, imports)).instance; - const wasm = wasmInstance.exports;", + const wasm = wasmInstance.exports; + export const __wasm = wasm;", module_name = module_name ) } diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index 8872c8b2797..cd735f28321 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml @@ -23,6 +23,7 @@ bin-dir = "wasm-bindgen-{ version }-{ target }/{ bin }{ binary-ext }" docopt = "1.0" env_logger = "0.8" anyhow = "1.0" +fs2 = "0.4.3" log = "0.4" native-tls = { version = "0.2", default-features = false, optional = true } rouille = { version = "3.0.0", default-features = false } diff --git a/crates/cli/src/bin/wasm-bindgen-test-runner/deno.rs b/crates/cli/src/bin/wasm-bindgen-test-runner/deno.rs index a0b05cdbd5b..9a9f39ea505 100644 --- a/crates/cli/src/bin/wasm-bindgen-test-runner/deno.rs +++ b/crates/cli/src/bin/wasm-bindgen-test-runner/deno.rs @@ -18,7 +18,7 @@ pub fn execute( {console_override} - // global.__wbg_test_invoke = f => f(); + window.__wbg_test_invoke = f => f(); // Forward runtime arguments. These arguments are also arguments to the // `wasm-bindgen-test-runner` which forwards them to deno which we @@ -26,11 +26,8 @@ pub fn execute( // filters for now. cx.args(Deno.args.slice(1)); - const ok = await cx.run(tests.map(n => wasm.__wasm[n])); - if (!ok) Deno.exit(1); - const tests = []; - "#, +"#, module, console_override = SHARED_SETUP, ); @@ -39,6 +36,11 @@ pub fn execute( js_to_execute.push_str(&format!("tests.push('{}')\n", test)); } + js_to_execute.push_str( + r#"const ok = await cx.run(tests.map(n => wasm.__wasm[n])); +if (!ok) Deno.exit(1);"#, + ); + let js_path = tmpdir.join("run.js"); fs::write(&js_path, js_to_execute).context("failed to write JS file")?; diff --git a/crates/cli/src/bin/wasm-bindgen-test-runner/headless.rs b/crates/cli/src/bin/wasm-bindgen-test-runner/headless.rs index f111902f73f..a4886800260 100644 --- a/crates/cli/src/bin/wasm-bindgen-test-runner/headless.rs +++ b/crates/cli/src/bin/wasm-bindgen-test-runner/headless.rs @@ -3,7 +3,7 @@ use anyhow::{bail, format_err, Context, Error}; use log::{debug, warn}; use rouille::url::Url; use serde::{Deserialize, Serialize}; -use serde_json::{self, json, Map, Value as Json}; +use serde_json::{json, Map, Value as Json}; use std::env; use std::fs::File; use std::io::{self, Read}; diff --git a/crates/cli/src/bin/wasm-bindgen-test-runner/main.rs b/crates/cli/src/bin/wasm-bindgen-test-runner/main.rs index 06d386119ed..11619a9f07b 100644 --- a/crates/cli/src/bin/wasm-bindgen-test-runner/main.rs +++ b/crates/cli/src/bin/wasm-bindgen-test-runner/main.rs @@ -12,7 +12,9 @@ //! and source code. use anyhow::{anyhow, bail, Context}; +use docopt::Docopt; use log::error; +use serde::Deserialize; use std::env; use std::fs; use std::path::PathBuf; @@ -65,16 +67,69 @@ impl Drop for TmpDirDeleteGuard { } } +const USAGE: &str = " +Execute all wasm bindgen unit and integration tests and build examples of a local package + +Usage: + wasm-bindgen-test-runner [options] [] [--include-ignored] [(--skip PATTERN)...] [--nocapture] + wasm-bindgen-test-runner [options] [--nocapture] --exact + wasm-bindgen-test-runner [options] --list [--format FORMAT] [--ignored] + wasm-bindgen-test-runner -h | --help + wasm-bindgen-test-runner -V | --version + +Options: + -h, --help Show this screen. + -V, --version Print the version number of wasm-bindgen-test-runner + + The wasm file to test + Run only the tests with the given name + +Arguments: + --include-ignored Include ignored tests in the test run + --skip PATTERN Skip tests whose names match the given pattern + --nocapture Disables the tests output capture + --exact Run only the test with the exact name + + --list List all tests that would be run + --format FORMAT Format of the tests listing output, valid values are [terse, json] + --ignored Restricts the listing to only consider the ignored tests + +Additional documentation: https://rustwasm.github.io/wasm-bindgen/wasm-bindgen-test/usage.html +"; + +#[derive(Debug, Deserialize)] +struct Args { + arg_input: Option, + arg_testname: Option, + flag_exact: bool, + flag_format: Option, + flag_include_ignored: bool, + flag_ignored: bool, + flag_list: bool, + flag_nocapture: bool, + flag_pattern: Vec, + flag_version: bool, +} + fn main() -> anyhow::Result<()> { env_logger::init(); - let mut args = env::args_os().skip(1); - let shell = shell::Shell::new(); - - // Currently no flags are supported, and assume there's only one argument - // which is the wasm file to test. This'll want to improve over time! - let wasm_file_to_test = match args.next() { - Some(file) => PathBuf::from(file), - None => bail!("must have a file to test as first argument"), + let args = env::args_os().skip(2); + let args_: Args = Docopt::new(USAGE) + .and_then(|d| d.deserialize()) + .unwrap_or_else(|e| e.exit()); + + if args_.flag_version { + println!( + "wasm-bindgen-test-runner {}", + wasm_bindgen_shared::version() + ); + return Ok(()); + } + + let wasm_file_to_test: PathBuf = if let Some(input) = args_.arg_input { + input + } else { + bail!("must have a file to test as first argument"); }; let file_name = wasm_file_to_test @@ -82,53 +137,57 @@ fn main() -> anyhow::Result<()> { .and_then(|s| s.to_str()) .context("file to test is not a valid file, can't extract file name")?; - // wasm_file_to_test may be - // - a cargo-like directory layout and generate output at - // `target/wasm32-unknown-unknown/...` - // - a tmp directory, generated by rustdoc - // we would like a directory we have write access to. if we assume cargo-like directories, - // we end up with the path `/wbg-out` - let wasm_file_str = wasm_file_to_test.to_string_lossy(); - let tmpdir = - if wasm_file_str.starts_with("/tmp/rustdoc") || wasm_file_str.starts_with("/var/folders") { - wasm_file_to_test.parent() // chop off the file name and give us the /tmp/rustdoc directory - } else { - wasm_file_to_test - .parent() // chop off file name - .and_then(|p| p.parent()) // chop off `deps` - .and_then(|p| p.parent()) // chop off `debug` - } - .map(|p| p.join(format!("wbg-tmp-{}", file_name))) - .ok_or_else(|| anyhow!("file to test doesn't follow the expected Cargo conventions"))?; - - // Make sure there's no stale state from before - drop(fs::remove_dir_all(&tmpdir)); - fs::create_dir(&tmpdir).context("creating temporary directory")?; - let _guard = TmpDirDeleteGuard(tmpdir.clone()); - - let module = "wasm-bindgen-test"; - - // Collect all tests that the test harness is supposed to run. We assume - // that any exported function with the prefix `__wbg_test` is a test we need - // to execute. let wasm = fs::read(&wasm_file_to_test).context("failed to read wasm file")?; let mut wasm = walrus::Module::from_buffer(&wasm).context("failed to deserialize wasm module")?; - let mut tests = Vec::new(); - for export in wasm.exports.iter() { - if !export.name.starts_with("__wbgt_") { - continue; + if args_.flag_list { + let mut found = false; + for export in wasm.exports.iter() { + if !export.name.starts_with("___wbgt_") { + continue; + } + + let parts: Vec<&str> = export.name.split('$').collect(); + + if args_.flag_ignored { + if parts.len() == 3 { + let test = parts[1]; + let test = &test[test.find("::").unwrap_or(0) + 2..]; + println!("{}: test", test); + } + } else { + let test = parts[1]; + let test = &test[test.find("::").unwrap_or(0) + 2..]; + println!("{}: test", test); + } + found = true; + } + + if !found || args_.flag_ignored { + return Ok(()); } - tests.push(export.name.to_string()); } - // Right now there's a bug where if no tests are present then the - // `wasm-bindgen-test` runtime support isn't linked in, so just bail out - // early saying everything is ok. - if tests.is_empty() { - println!("no tests to run!"); - return Ok(()); + let mut tests = Vec::new(); + if !args_.flag_list { + // Collect all tests that the test harness is supposed to run. We assume + // that any exported function with the prefix `__wbg_test` is a test we need + // to execute. + for export in wasm.exports.iter() { + if !export.name.starts_with("__wbgt_") { + continue; + } + tests.push(export.name.to_string()); + } + + // Right now there's a bug where if no tests are present then the + // `wasm-bindgen-test` runtime support isn't linked in, so just bail out + // early saying everything is ok. + if tests.is_empty() { + println!("no tests to run!"); + return Ok(()); + } } // Figure out if this tests is supposed to execute in node.js or a browser. @@ -152,6 +211,9 @@ fn main() -> anyhow::Result<()> { }, Some(_) => bail!("invalid __wasm_bingen_test_unstable value"), None if std::env::var("WASM_BINDGEN_USE_DENO").is_ok() => TestMode::Deno, + None if std::env::var("WASM_BINDGEN_USE_BROWSER").is_ok() => TestMode::Browser { + no_modules: std::env::var("WASM_BINDGEN_USE_NO_MODULE").is_ok(), + }, None => TestMode::Node, }; @@ -184,6 +246,87 @@ fn main() -> anyhow::Result<()> { return Ok(()); } + let module = "wasm-bindgen-test"; + + // wasm_file_to_test may be + // - a cargo-like directory layout and generate output at + // `target/wasm32-unknown-unknown/...` + // - a tmp directory, generated by rustdoc + // we would like a directory we have write access to. if we assume cargo-like directories, + // we end up with the path `/wbg-out` + let wasm_file_str = wasm_file_to_test.to_string_lossy(); + let tmpdir = + if wasm_file_str.starts_with("/tmp/rustdoc") || wasm_file_str.starts_with("/var/folders") { + wasm_file_to_test.parent() // chop off the file name and give us the /tmp/rustdoc directory + } else { + wasm_file_to_test + .parent() // chop off file name + .and_then(|p| p.parent()) // chop off `deps` + .and_then(|p| p.parent()) // chop off `debug` + } + .map(|p| p.join(format!("wbg-tmp-{}", file_name))) + .ok_or_else(|| anyhow!("file to test doesn't follow the expected Cargo conventions"))?; + + let shell = if !args_.flag_list { + Some(shell::Shell::new()) + } else { + None + }; + let _guard = if args_.flag_list || args_.flag_exact { + None + } else { + Some(TmpDirDeleteGuard(tmpdir.clone())) + }; + + if !args_.flag_exact || !tmpdir.exists() { + // Make sure there's no stale state from before + drop(fs::remove_dir_all(&tmpdir)); + fs::create_dir(&tmpdir).context("creating temporary directory")?; + + // Make the generated bindings available for the tests to execute against. + if let Some(ref shell) = shell { + shell.status("Executing bindgen..."); + } + let mut b = Bindgen::new(); + match test_mode { + TestMode::Node => b.nodejs(true)?, + TestMode::Deno => b.deno(true)?, + TestMode::Browser { .. } + | TestMode::DedicatedWorker { .. } + | TestMode::SharedWorker { .. } + | TestMode::ServiceWorker { .. } => { + if test_mode.no_modules() { + b.no_modules(true)? + } else { + b.web(true)? + } + } + }; + + if std::env::var("WASM_BINDGEN_SPLIT_LINKED_MODULES").is_ok() { + b.split_linked_modules(true); + } + + b.debug(debug) + .input_module(module, wasm) + .keep_debug(false) + .emit_start(false) + .generate(&tmpdir) + .context("executing `wasm-bindgen` over the wasm file")?; + + if let Some(ref shell) = shell { + shell.clear(); + } + } + + if args_.flag_list { + return Ok(()); + } + + let Some(shell) = shell else { + bail!("no shell available"); + }; + let timeout = env::var("WASM_BINDGEN_TEST_TIMEOUT") .map(|timeout| { timeout @@ -196,36 +339,6 @@ fn main() -> anyhow::Result<()> { println!("Set timeout to {} seconds...", timeout); } - // Make the generated bindings available for the tests to execute against. - shell.status("Executing bindgen..."); - let mut b = Bindgen::new(); - match test_mode { - TestMode::Node => b.nodejs(true)?, - TestMode::Deno => b.deno(true)?, - TestMode::Browser { .. } - | TestMode::DedicatedWorker { .. } - | TestMode::SharedWorker { .. } - | TestMode::ServiceWorker { .. } => { - if test_mode.no_modules() { - b.no_modules(true)? - } else { - b.web(true)? - } - } - }; - - if std::env::var("WASM_BINDGEN_SPLIT_LINKED_MODULES").is_ok() { - b.split_linked_modules(true); - } - - b.debug(debug) - .input_module(module, wasm) - .keep_debug(false) - .emit_start(false) - .generate(&tmpdir) - .context("executing `wasm-bindgen` over the wasm file")?; - shell.clear(); - let args: Vec<_> = args.collect(); match test_mode { diff --git a/crates/cli/src/bin/wasm-bindgen-test-runner/node.rs b/crates/cli/src/bin/wasm-bindgen-test-runner/node.rs index c90d00251ba..0e1718119ae 100644 --- a/crates/cli/src/bin/wasm-bindgen-test-runner/node.rs +++ b/crates/cli/src/bin/wasm-bindgen-test-runner/node.rs @@ -30,7 +30,7 @@ wrap("info"); wrap("warn"); wrap("error"); -cx = new wasm.WasmBindgenTestContext(); +const cx = new wasm.WasmBindgenTestContext(); handlers.on_console_debug = wasm.__wbgtest_console_debug; handlers.on_console_log = wasm.__wbgtest_console_log; handlers.on_console_info = wasm.__wbgtest_console_info; @@ -117,7 +117,10 @@ pub fn execute( #[cfg(unix)] pub fn exec(cmd: &mut Command) -> Result<(), Error> { use std::os::unix::prelude::*; - Err(Error::from(cmd.exec()).context("failed to execute `node`")) + Err(Error::from(cmd.exec()).context(format!( + "failed to execute `{}`", + cmd.get_program().to_string_lossy() + ))) } #[cfg(windows)] diff --git a/crates/test-macro/src/lib.rs b/crates/test-macro/src/lib.rs index c3829df823c..bc2e4418dd4 100644 --- a/crates/test-macro/src/lib.rs +++ b/crates/test-macro/src/lib.rs @@ -80,6 +80,12 @@ pub fn wasm_bindgen_test( None => quote! { ::core::option::Option::None }, }; + let ignore_str = match ignore.clone() { + Some(Some(_)) => "$", + Some(None) => "$", + None => "", + }; + let ignore = match ignore { Some(Some(lit)) => { quote! { ::core::option::Option::Some(::core::option::Option::Some(#lit)) } @@ -99,8 +105,14 @@ pub fn wasm_bindgen_test( // main test harness. This is the entry point for all tests. let name = format_ident!("__wbgt_{}_{}", ident, CNT.fetch_add(1, Ordering::SeqCst)); let wasm_bindgen_path = attributes.wasm_bindgen_path; + let ident_str = ident.to_string(); + let name_str = name.to_string(); + let aux = format_ident!("_{}", name_str); tokens.extend( quote! { + #[export_name = concat!("_", #name_str, "$", module_path!(), "::", #ident_str, #ignore_str)] + pub extern "C" fn #aux() {} + #[no_mangle] pub extern "C" fn #name(cx: &#wasm_bindgen_path::__rt::Context) { let test_name = ::core::concat!(::core::module_path!(), "::", ::core::stringify!(#ident)); diff --git a/crates/test/src/rt/detect.rs b/crates/test/src/rt/detect.rs index 235b14c67d6..f4cdd988d59 100644 --- a/crates/test/src/rt/detect.rs +++ b/crates/test/src/rt/detect.rs @@ -12,6 +12,11 @@ extern "C" { #[wasm_bindgen(method, getter, structural)] fn constructor(me: &Scope) -> Constructor; + #[wasm_bindgen(method, getter, structural, js_name = Deno)] + fn deno(me: &Scope) -> Option; + + type Deno; + type Constructor; #[wasm_bindgen(method, getter, structural)] fn name(me: &Constructor) -> String; @@ -27,7 +32,10 @@ pub fn detect() -> Runtime { "DedicatedWorkerGlobalScope" | "SharedWorkerGlobalScope" | "ServiceWorkerGlobalScope" => Runtime::Worker, - _ => Runtime::Browser, + _ => match scope.deno() { + Some(_) => Runtime::Node, + _ => Runtime::Browser, + }, }, None => Runtime::Node, } diff --git a/crates/test/src/rt/mod.rs b/crates/test/src/rt/mod.rs index c1be2904303..2d6086ffbb1 100644 --- a/crates/test/src/rt/mod.rs +++ b/crates/test/src/rt/mod.rs @@ -121,6 +121,9 @@ pub struct Context { } struct State { + /// Restricts the filter to be strict, that is only allow exact match + exact: Cell, + /// An optional filter used to restrict which tests are actually executed /// and which are ignored. This is passed via the `args` function which /// comes from the command line of `wasm-bindgen-test-runner`. Currently @@ -130,6 +133,9 @@ struct State { /// Include ignored tests. include_ignored: Cell, + /// Disabled the test output capture + nocapture: Cell, + /// Tests to skip. skip: RefCell>, @@ -159,6 +165,9 @@ struct State { /// How to actually format output, either node.js or browser-specific /// implementation. formatter: Box, + + /// Total tests + tests: Cell, } /// Failure reasons. @@ -281,8 +290,10 @@ impl Context { Context { state: Rc::new(State { + exact: Default::default(), filter: Default::default(), include_ignored: Default::default(), + nocapture: Default::default(), skip: Default::default(), failures: Default::default(), filtered: Default::default(), @@ -291,6 +302,7 @@ impl Context { running: Default::default(), succeeded: Default::default(), formatter, + tests: Default::default(), }), } } @@ -316,6 +328,10 @@ impl Context { ); } else if let Some(arg) = arg.strip_prefix("--skip=") { skip.push(arg.to_owned()) + } else if arg == "--nocapture" { + self.state.nocapture.set(true); + } else if arg == "--exact" { + self.state.exact.set(true); } else if arg.starts_with('-') { panic!("flag {} not supported", arg); } else if filter.is_some() { @@ -336,11 +352,11 @@ impl Context { /// The promise returned resolves to either `true` if all tests passed or /// `false` if at least one test failed. pub fn run(&self, tests: Vec) -> Promise { - let noun = if tests.len() == 1 { "test" } else { "tests" }; - self.state - .formatter - .writeln(&format!("running {} {}", tests.len(), noun)); - self.state.formatter.writeln(""); + if !self.state.exact.get() { + self.state.print_running_tests(tests.len()); + } else { + self.state.tests.set(tests.len()); + } // Execute all our test functions through their wasm shims (unclear how // to pass native function pointers around here). Each test will @@ -483,6 +499,22 @@ impl Context { ) } + fn filter(&self, name: &str) -> bool { + let filter = self.state.filter.borrow(); + let exact = self.state.exact.get(); + + if let Some(filter) = &*filter { + if exact { + let test_name = &name[name.find("::").unwrap() + 2..]; + test_name != filter + } else { + !name.contains(filter) + } + } else { + false + } + } + fn execute( &self, name: &str, @@ -492,13 +524,10 @@ impl Context { ) { // If our test is filtered out, record that it was filtered and move // on, nothing to do here. - let filter = self.state.filter.borrow(); - if let Some(filter) = &*filter { - if !name.contains(filter) { - let filtered = self.state.filtered.get(); - self.state.filtered.set(filtered + 1); - return; - } + if self.filter(name) { + let filtered = self.state.filtered.get(); + self.state.filtered.set(filtered + 1); + return; } for skip in &*self.state.skip.borrow() { @@ -520,6 +549,10 @@ impl Context { } } + if self.state.exact.get() { + self.state.print_running_tests(1); + } + // Looks like we've got a test that needs to be executed! Push it onto // the list of remaining tests. let output = Output { @@ -589,6 +622,10 @@ impl Future for ExecuteTests { // so we shouldn't have any more remaining tests either. assert_eq!(remaining.len(), 0); + if self.0.exact.get() && self.0.tests.get() == self.0.filtered.get() { + self.0.print_running_tests(0); + } + self.0.print_results(); let all_passed = self.0.failures.borrow().len() == 0; Poll::Ready(all_passed) @@ -632,6 +669,13 @@ impl State { } } + fn print_running_tests(&self, count: usize) { + let noun = if count == 1 { "test" } else { "tests" }; + self.formatter + .writeln(&format!("running {} {}", count, noun)); + self.formatter.writeln(""); + } + fn print_results(&self) { let failures = self.failures.borrow(); if failures.len() > 0 { diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/mod.rs new file mode 100644 index 00000000000..9c1eab26336 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/mod.rs @@ -0,0 +1,4 @@ +mod options; +mod runtimes; +mod with_an_assembly; +mod without_arguments; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/mod.rs new file mode 100644 index 00000000000..1e1b94d44eb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_wasm_bindgen_test_runner_help_information_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs new file mode 100644 index 00000000000..ac0663b9409 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs @@ -0,0 +1,42 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn outputs_the_wasm_bindgen_test_runner_help_information_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "--help"); + then_the_standard_output_should_have( + &context, + r#"Execute all wasm bindgen unit and integration tests and build examples of a local package + +Usage: + wasm-bindgen-test-runner [options] [] [--include-ignored] [(--skip PATTERN)...] [--nocapture] + wasm-bindgen-test-runner [options] [--nocapture] --exact + wasm-bindgen-test-runner [options] --list [--format FORMAT] [--ignored] + wasm-bindgen-test-runner -h | --help + wasm-bindgen-test-runner -V | --version + +Options: + -h, --help Show this screen. + -V, --version Print the version number of wasm-bindgen-test-runner + + The wasm file to test + Run only the tests with the given name + +Arguments: + --include-ignored Include ignored tests in the test run + --skip PATTERN Skip tests whose names match the given pattern + --nocapture Disables the tests output capture + --exact Run only the test with the exact name + + --list List all tests that would be run + --format FORMAT Format of the tests listing output, valid values are [terse, json] + --ignored Restricts the listing to only consider the ignored tests + +Additional documentation: https://rustwasm.github.io/wasm-bindgen/wasm-bindgen-test/usage.html +"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/returns_success_feature.rs new file mode 100644 index 00000000000..5646cf0e1e6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__help/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "--help"); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/mod.rs new file mode 100644 index 00000000000..bb037e0f91c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_wasm_bindgen_test_runner_version_information_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs new file mode 100644 index 00000000000..29d37056be1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn outputs_the_wasm_bindgen_test_runner_version_information_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "--version"); + then_the_standard_output_should_have( + &context, + &format!("wasm-bindgen-test-runner {}", env!("CARGO_PKG_VERSION")), + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/returns_success_feature.rs new file mode 100644 index 00000000000..8a6631b2171 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/__version/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "--version"); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/mod.rs new file mode 100644 index 00000000000..1e1b94d44eb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_wasm_bindgen_test_runner_help_information_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs new file mode 100644 index 00000000000..72309f4249f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/outputs_the_wasm_bindgen_test_runner_help_information_feature.rs @@ -0,0 +1,42 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn outputs_the_wasm_bindgen_test_runner_help_information_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "-h"); + then_the_standard_output_should_have( + &context, + r#"Execute all wasm bindgen unit and integration tests and build examples of a local package + +Usage: + wasm-bindgen-test-runner [options] [] [--include-ignored] [(--skip PATTERN)...] [--nocapture] + wasm-bindgen-test-runner [options] [--nocapture] --exact + wasm-bindgen-test-runner [options] --list [--format FORMAT] [--ignored] + wasm-bindgen-test-runner -h | --help + wasm-bindgen-test-runner -V | --version + +Options: + -h, --help Show this screen. + -V, --version Print the version number of wasm-bindgen-test-runner + + The wasm file to test + Run only the tests with the given name + +Arguments: + --include-ignored Include ignored tests in the test run + --skip PATTERN Skip tests whose names match the given pattern + --nocapture Disables the tests output capture + --exact Run only the test with the exact name + + --list List all tests that would be run + --format FORMAT Format of the tests listing output, valid values are [terse, json] + --ignored Restricts the listing to only consider the ignored tests + +Additional documentation: https://rustwasm.github.io/wasm-bindgen/wasm-bindgen-test/usage.html +"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/returns_success_feature.rs new file mode 100644 index 00000000000..5a510db2f38 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_h/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "-h"); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/mod.rs new file mode 100644 index 00000000000..bb037e0f91c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_wasm_bindgen_test_runner_version_information_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs new file mode 100644 index 00000000000..a0b9b572957 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/outputs_the_wasm_bindgen_test_runner_version_information_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn outputs_the_wasm_bindgen_test_runner_version_information_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "-V"); + then_the_standard_output_should_have( + &context, + &format!("wasm-bindgen-test-runner {}", env!("CARGO_PKG_VERSION")), + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/returns_success_feature.rs new file mode 100644 index 00000000000..51ca7e9b1a5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/_v/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_option; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_option(&mut context, "-V"); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/options/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/options/mod.rs new file mode 100644 index 00000000000..7ecd3f18e40 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/options/mod.rs @@ -0,0 +1,4 @@ +mod __help; +mod __version; +mod _h; +mod _v; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/mod.rs new file mode 100644 index 00000000000..db99b0bac03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/mod.rs @@ -0,0 +1 @@ +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..2289f314b89 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..258f256085a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..e2c99e90765 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..72490f4ae9d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..3dd3b1f5a95 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/deno/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/mod.rs new file mode 100644 index 00000000000..db99b0bac03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/mod.rs @@ -0,0 +1 @@ +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..f3b75e5f956 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..4b6716ed170 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..3102f8b6b37 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..7aa2195a05d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..afcc8105739 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/firefox/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/mod.rs new file mode 100644 index 00000000000..dc0538e69b3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/mod.rs @@ -0,0 +1,3 @@ +mod deno; +mod firefox; +mod node; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/mod.rs new file mode 100644 index 00000000000..db99b0bac03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/mod.rs @@ -0,0 +1 @@ +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..6f365c0cdcb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..211e0d6960d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..84330951590 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..91d5f7519ef --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..c3dc52b2c94 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/runtimes/node/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/mod.rs new file mode 100644 index 00000000000..b47b1f57f63 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/mod.rs @@ -0,0 +1,2 @@ +mod with_arguments; +mod without_arguments; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/mod.rs new file mode 100644 index 00000000000..4ca47c84090 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/mod.rs @@ -0,0 +1,6 @@ +mod with_one_failing_test; +mod with_one_ignored_test; +mod with_one_ignored_with_reason_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/mod.rs new file mode 100644 index 00000000000..a1167f8d4ad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_1_test_feature; +mod outputs_the_assembly_failure_summary_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_failed_test_assertion_error_feature; +mod outputs_the_failed_test_summary_feature; +mod returns_failure_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..73702c48b3f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs new file mode 100644 index 00000000000..644bc52ecc7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_failure_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "failures:\n\n assembly_with_one_failing_test::fail", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..bf4cd5edbc6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs new file mode 100644 index 00000000000..0106fc85a1b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_assertion_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_error_should_have( + &context, + "assertion `left == right` failed\n left: 1\n right: 2", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs new file mode 100644 index 00000000000..cadbcddc111 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_failing_test::fail ... FAIL", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/returns_failure_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/returns_failure_feature.rs new file mode 100644 index 00000000000..1e87eac8382 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_failing_test/returns_failure_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::error_code::then_failure_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_failure_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_failure_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..c40ba06016b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_successful_execution_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..cf8ed6aad02 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..c3d5bd0613b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..48fa4a8ec2e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_ignored_test_successful_execution_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_ignored_test_successful_execution_summary_feature.rs new file mode 100644 index 00000000000..65729651ab3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/outputs_the_ignored_test_successful_execution_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_successful_execution_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_ignored_test::ignored ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..936fa844629 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/mod.rs new file mode 100644 index 00000000000..c40ba06016b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_successful_execution_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..e16094c68a7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..d30a05565f8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..7b1105fed08 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_successful_execution_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_successful_execution_summary_feature.rs new file mode 100644 index 00000000000..838bf6d2f66 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_successful_execution_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_successful_execution_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_ignored_with_reason_test::ignored ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs new file mode 100644 index 00000000000..b48a604f434 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..e4b0a4ed3f8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,7 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_the_assembly_failure_summary_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_failed_test_assertion_error_feature; +mod outputs_the_failed_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_failure_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..80bbbd74c86 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs new file mode 100644 index 00000000000..e7ff4202083 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_failure_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "failures:\n\n assembly_with_one_successful_and_one_failing_tests::fail\n", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..b7400b1d582 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: FAILED. 1 passed; 1 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs new file mode 100644 index 00000000000..5f1fbfce069 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_assertion_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_error_should_have( + &context, + "assertion `left == right` failed\n left: 1\n right: 2", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs new file mode 100644 index 00000000000..c8868825063 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_failing_tests::fail ... FAIL", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..96b0e39dde5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_failing_tests::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs new file mode 100644 index 00000000000..aa5016d13d6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::error_code::then_failure_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_failure_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_failure_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..307645a1f9a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_successful_execution_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..385e94b5068 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..1fc2c899342 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 2 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_successful_execution_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_successful_execution_summary_feature.rs new file mode 100644 index 00000000000..283cab283f9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_successful_execution_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_successful_execution_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_ignored_tests::ignored ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..2a525df7843 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_successful_execution_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_ignored_tests::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..5f2f861fe2e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..21fc8bfdf51 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..aadee81f6a1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..a39680b7c46 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..48b9943ca6d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..f9be0a78d65 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/level_0/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--include-ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/mod.rs new file mode 100644 index 00000000000..c287a1a3df5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__include_ignored/mod.rs @@ -0,0 +1 @@ +mod level_0; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/mod.rs new file mode 100644 index 00000000000..74919297df5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/mod.rs @@ -0,0 +1,4 @@ +mod with_one_ignored_test; +mod with_one_ignored_with_reason_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..703eb43cf12 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..1d59c4b8d5c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..f09ed1a68ba --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs new file mode 100644 index 00000000000..9c4b70e5f04 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..78d02776662 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_nothing_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs new file mode 100644 index 00000000000..d58e4db180f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_nothing_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs new file mode 100644 index 00000000000..a7941478876 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..58c4d30934d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_ignored_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..49776e97fca --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..ef4bff0ad31 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/mod.rs new file mode 100644 index 00000000000..f340801fa96 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/mod.rs @@ -0,0 +1,3 @@ +mod with_one_ignored_test; +mod with_one_successful_and_one_failing_test; +mod with_one_successful_and_one_ignored_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..21d4f369668 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"level_1::ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..0f9bdb24f66 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/mod.rs new file mode 100644 index 00000000000..78d02776662 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_nothing_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/outputs_nothing_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/outputs_nothing_feature.rs new file mode 100644 index 00000000000..c25f3166911 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/outputs_nothing_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_nothing_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs new file mode 100644 index 00000000000..fd6e1bcbd49 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..58c4d30934d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_ignored_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..4d3ec213806 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"level_1::ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..1f394b13d77 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_1/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/mod.rs new file mode 100644 index 00000000000..248266f43f5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/mod.rs @@ -0,0 +1,3 @@ +mod with_one_ignored_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..e34fe312691 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_level_2_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"level_1::level_2::ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..094d0d52694 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_level_2_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..78d02776662 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_nothing_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs new file mode 100644 index 00000000000..8e4db746ebf --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/outputs_nothing_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_nothing_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/returns_success_feature.rs new file mode 100644 index 00000000000..3301c031207 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_failing_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..58c4d30934d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_ignored_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..e10c77c47ca --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_have(&context, r#"level_1::level_2::ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..0e33872cf99 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/level_2/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/mod.rs new file mode 100644 index 00000000000..a2590091967 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/mod.rs @@ -0,0 +1,4 @@ +mod level_0; +mod level_1; +mod level_2; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/mod.rs new file mode 100644 index 00000000000..78d02776662 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_nothing_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/outputs_nothing_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/outputs_nothing_feature.rs new file mode 100644 index 00000000000..50dfefaa994 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/outputs_nothing_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_nothing_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_the_standard_output_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..2ac3a95d2c0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/__ignored/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse --ignored", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/mod.rs new file mode 100644 index 00000000000..74919297df5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/mod.rs @@ -0,0 +1,4 @@ +mod with_one_ignored_test; +mod with_one_ignored_with_reason_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/lists_the_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/lists_the_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..8c8cf7128e8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/lists_the_tests_in_the_terse_format_feature.rs @@ -0,0 +1,21 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; +use auroka_morpheus_macros_feature::feature; + +feature! { + given_there_is_an_assembly_with_one_ignored_test(); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + "--list --format terse", + ); + + "Ouputs the test in the terse format" { + then_the_standard_output_should_have("ignored: test"); + } + + "Returns success" { + then_success_should_have_been_returned(); + } +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..9c26b46a215 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/mod.rs @@ -0,0 +1,3 @@ +//mod lists_the_tests_in_the_terse_format_feature; +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..8a1303d073f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have(&context, r#"ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..399054c71b2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..98ad62e71cb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have(&context, r#"ignored: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs new file mode 100644 index 00000000000..454b4f930df --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..0bb8c9c9b87 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"pass: test +fail: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs new file mode 100644 index 00000000000..73f842bea13 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_failing_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..e1150fc988d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"pass: test +ignored: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..301563edf6b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/mod.rs new file mode 100644 index 00000000000..ccd2436f99d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/mod.rs @@ -0,0 +1,3 @@ +mod with_one_successful_and_one_failing_test; +mod with_one_successful_and_one_ignored_test; +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..31eddcad5b5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"level_1::pass: test +level_1::fail: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs new file mode 100644 index 00000000000..5ace5887c2e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_failing_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..a8e43d28cf1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"level_1::pass: test +level_1::ignored: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..7ac9183ffb1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_and_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..2e6f20569c3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_test_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have(&context, r#"level_1::pass: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..81d00b5f75f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_1/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/mod.rs new file mode 100644 index 00000000000..ccd2436f99d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/mod.rs @@ -0,0 +1,3 @@ +mod with_one_successful_and_one_failing_test; +mod with_one_successful_and_one_ignored_test; +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..c3874180899 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"level_1::level_2::pass: test +level_1::level_2::fail: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/returns_success_feature.rs new file mode 100644 index 00000000000..3524b18af70 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_failing_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/mod.rs new file mode 100644 index 00000000000..2fe6eb0f83f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_all_tests_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..e7162c43b4d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/outputs_all_tests_in_the_terse_format_feature.rs @@ -0,0 +1,19 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_all_tests_in_the_terse_format_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have( + &context, + r#"level_1::level_2::pass: test +level_1::level_2::ignored: test"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..8d20b80918f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_and_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..be94fe3d391 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/mod.rs @@ -0,0 +1,2 @@ +mod outputs_the_test_in_the_terse_format_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs new file mode 100644 index 00000000000..2275f4df246 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/outputs_the_test_in_the_terse_format_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_have(&context, r#"level_1::level_2::pass: test"#); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..a5834e5f8e2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/level_2/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/mod.rs new file mode 100644 index 00000000000..a2590091967 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/mod.rs @@ -0,0 +1,4 @@ +mod level_0; +mod level_1; +mod level_2; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/mod.rs new file mode 100644 index 00000000000..78d02776662 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_nothing_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/outputs_nothing_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/outputs_nothing_feature.rs new file mode 100644 index 00000000000..1ddbc69080c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/outputs_nothing_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_nothing_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_the_standard_output_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..cf2ce970b7d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/default/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--list --format terse", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/mod.rs new file mode 100644 index 00000000000..e505b9b3dfd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/__format_terse/mod.rs @@ -0,0 +1,2 @@ +mod __ignored; +mod default; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/mod.rs new file mode 100644 index 00000000000..e418dac0297 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__list/mod.rs @@ -0,0 +1 @@ +mod __format_terse; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/mod.rs new file mode 100644 index 00000000000..60167028c54 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/mod.rs @@ -0,0 +1,6 @@ +mod with_one_full_match_successful_test; +mod with_one_partial_match_successful_test; +mod with_one_prefix_match_successful_test; +mod with_one_suffix_match_successful_test; +mod with_two_partial_match_successful_tests; +mod without_match_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..ca4db76c506 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..54f51e2588b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..9316b8a491c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..04185627d65 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..a6bbc4e4600 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..6bbf75e6406 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=as", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..af1d3022cb9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=as", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..cf39cf3f45d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=as", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..42141677669 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=as", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..ff1d19f06b2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=as", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..82a3c9a9b53 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pa", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..b8138170fe7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pa", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..68a63b6629c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pa", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..9c69b1ca5d5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pa", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..4b41d943c03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pa", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..ab826e88eda --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..e2d02ba026d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..8824537da36 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..c54b88f53a5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..acdc52c1fe8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..b5ebdc017e2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..1358c48ca1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..2d265330617 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..ce2637ba5d1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..443613454ed --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..bef2b885035 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..cd989383c6d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..ade91b782df --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..edac61892c6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..2c2d60258ba --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..11f21ff8244 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/mod.rs new file mode 100644 index 00000000000..60167028c54 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/mod.rs @@ -0,0 +1,6 @@ +mod with_one_full_match_successful_test; +mod with_one_partial_match_successful_test; +mod with_one_prefix_match_successful_test; +mod with_one_suffix_match_successful_test; +mod with_two_partial_match_successful_tests; +mod without_match_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..fb7834d91a5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1::pass", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..b0eb06bacd3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1::pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..4ef0b8a298c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1::pass", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..6e3c7f134ad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1::pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..bc7e45f1547 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1::pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..8cfbc64e470 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=1::", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..0526c51f7be --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=1::", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..db4fadb2ef6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=1::", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..cbf3a02651b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=1::", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..50a8ee84420 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=1::", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..ac864153c45 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..9cc1d493527 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..55ea8c4a5a4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..1b1944e4df6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..f5fdd55ec49 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=level_1", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..a97dd6bfd0c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..c7ce74349a1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..5007ea7fb90 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..8fe7ecc2350 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..e14eab5efbf --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=ss", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..a9e71575332 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..9f2406facbc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..30355bccbec --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..d8e480e7153 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..7bcae2e959f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..1caa22b1641 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..f5734bb4c26 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..5137403dca7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..189484d711f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..8ac6d5b8997 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_level_1_test::level_1::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..9037069cc00 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..8f248275fb5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..b13cd5471d2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_1/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..4872d185180 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..15405aae49e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..fc103f21c8f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..9eb15a98abd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..4fa575d9110 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..ed6eca52319 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=pass_2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..a0b93d6becd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..f0537043703 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..8c256daefb2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..685d5e01604 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..fe2402bac70 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..dd2aa11626e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pass_1 --skip=level_1", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..cf988cd4c2f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern1 --skip=pattern2", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..459ac43957a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_2/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern1 --skip=pattern2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..94af2aea6ff --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..353a0373e98 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..3524a6246a5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..bb5c427962d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..4d98636abd6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..5e3e07275af --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=fail --skip=pass_1 --skip=pass_2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..f34ae97b6dc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..71cecdc561c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..72b1db69f42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..deafc9f8408 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..3ea07d92105 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..dfae4817a49 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip level_1", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..0b10f720326 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern1 --skip=pattern2 --skip=pattern3", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..75ada6f3340 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/count_3/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip=pattern1 --skip=pattern2 --skip=pattern3", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/mod.rs new file mode 100644 index 00000000000..4436fd24ae0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_eq_pattern/mod.rs @@ -0,0 +1,3 @@ +mod count_1; +mod count_2; +mod count_3; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/mod.rs new file mode 100644 index 00000000000..60167028c54 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/mod.rs @@ -0,0 +1,6 @@ +mod with_one_full_match_successful_test; +mod with_one_partial_match_successful_test; +mod with_one_prefix_match_successful_test; +mod with_one_suffix_match_successful_test; +mod with_two_partial_match_successful_tests; +mod without_match_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..1d54d3cf46c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..4913fa80a89 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..27a9b578261 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..f5521052669 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..b24c47e9a99 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_full_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..5aaebf62a62 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip as", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..3562bf2f428 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip as", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..5208d237a68 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip as", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..9704223ed73 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip as", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..e7f16779e59 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_partial_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip as", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..6decabd868d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pa", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..6a0bf21844c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pa", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..755e7a6f3a2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pa", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..3979facb611 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pa", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..846124205b2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_prefix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pa", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..9c209971471 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..bb7984ce4f9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..d6534832a6e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..ccbd1346ac4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..a69f9274c43 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_one_suffix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..c50197585f4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..e5b5bf3dbb1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..4899d87df08 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..885d2ada742 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..a5c90b8ff20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..697487ad26f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..7aababd1e90 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..332acd03fbe --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..01e231fbc8a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..e09e43b1dad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..724c53441ed --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_0/without_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/mod.rs new file mode 100644 index 00000000000..60167028c54 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/mod.rs @@ -0,0 +1,6 @@ +mod with_one_full_match_successful_test; +mod with_one_partial_match_successful_test; +mod with_one_prefix_match_successful_test; +mod with_one_suffix_match_successful_test; +mod with_two_partial_match_successful_tests; +mod without_match_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..953585c84af --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1::pass", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..6841aeb2d34 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1::pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..94dbe635c40 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1::pass", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..3658591dcc1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1::pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..e25b27a6483 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_full_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1::pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..7efde920ff8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip 1::", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..513b8feaee3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip 1::", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..1468ecd29bb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip 1::", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..c6cdc790503 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip 1::", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..4e8a4f76719 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_partial_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip 1::", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..1ff5be75b26 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..115b9cb7b79 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..f6e9519ea2e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..dc451ca8ccf --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..9960ec353b7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_prefix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip level_1", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..f1beb1caf14 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..98e62c858a1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..6ea2922d154 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..4a9736d3fbd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..8718b418014 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_one_suffix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip ss", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..e18002ebcb6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..76686fa887b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..2c25374fce6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..3786ea789a8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..75163f06678 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..32eba739426 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..c827e99cdd6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..99d3de866e6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..4161fa609a4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..21f48b017a8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_level_1_test::level_1::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..f544aa31ed0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/level_1/without_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..750ba2f7c9b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..3cb9566b133 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_1/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..effdcb25094 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..965d519fd55 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..43a43c070ad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..b5a207adcb7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..fa7dfd1b60a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..867e27e0c82 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip pass_2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..c09f6245b55 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..96386748ae9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..e5d1efc580e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..6b5b0130f5b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..809aed13fba --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..a55183d8f5a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pass_1 --skip level_1", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..8cc9a36128c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern1 --skip pattern2", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..853a6d28329 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_2/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern1 --skip pattern2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..58d43e324d9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..c9da73ed664 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..aaa78c8588f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..987c9f4c9e8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..71be8625186 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..22d76076318 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_0/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/mod.rs new file mode 100644 index 00000000000..593a4002418 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/mod.rs @@ -0,0 +1 @@ +mod with_two_partial_match_successful_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..20549276099 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_1_feature; +mod outputs_no_information_about_the_skipped_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..e7e3890eb5b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..de08973608a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs new file mode 100644 index 00000000000..ad4c1dcbc19 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs new file mode 100644 index 00000000000..6574783ef19 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_no_information_about_the_skipped_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..a9607993039 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..ddade3af7f5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/level_1/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_level_1_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_level_1_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip fail --skip pass_1 --skip pass_2", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/mod.rs new file mode 100644 index 00000000000..331a0003e42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/mod.rs @@ -0,0 +1,3 @@ +mod level_0; +mod level_1; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/mod.rs new file mode 100644 index 00000000000..c7accad4a1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/mod.rs @@ -0,0 +1,2 @@ +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..64b4a170bc0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern1 --skip pattern2 --skip pattern3", + ); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..ec422d7be59 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/count_3/without_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "--skip pattern1 --skip pattern2 --skip pattern3", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/mod.rs new file mode 100644 index 00000000000..4436fd24ae0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/__skip_pattern/mod.rs @@ -0,0 +1,3 @@ +mod count_1; +mod count_2; +mod count_3; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/mod.rs new file mode 100644 index 00000000000..1f486f736cb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/mod.rs @@ -0,0 +1,5 @@ +mod __include_ignored; +mod __list; +mod __skip_eq_pattern; +mod __skip_pattern; +mod testname; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/mod.rs new file mode 100644 index 00000000000..a91ed4f294f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/mod.rs @@ -0,0 +1,4 @@ +mod with_partial_test_match; +mod with_successful_test_match_1_of_2; +mod with_successful_test_match_2_of_2; +mod without_test_match; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/mod.rs new file mode 100644 index 00000000000..c4cbfed6801 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_0_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_test_1_feature; +mod outputs_no_information_about_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_its_running_0_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_its_running_0_tests_feature.rs new file mode 100644 index 00000000000..e91d110dfec --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_its_running_0_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_0_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "running 0 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_error_feature.rs new file mode 100644 index 00000000000..dceff8e9661 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_1_feature.rs new file mode 100644 index 00000000000..57c31a9dae7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_2_feature.rs new file mode 100644 index 00000000000..a86b995dbd4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_no_information_about_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..94d490c8fd3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/returns_success_feature.rs new file mode 100644 index 00000000000..1b05be2b066 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_partial_test_match/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass --nocapture --exact", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/mod.rs new file mode 100644 index 00000000000..0a9f5d982a4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/mod.rs @@ -0,0 +1,7 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_1_standard_output_feature; +mod outputs_the_successful_test_1_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..aff31c9ef70 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_error_feature.rs new file mode 100644 index 00000000000..b5e7ccbeace --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_information_about_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_information_about_test_2_feature.rs new file mode 100644 index 00000000000..0a8d2c59b94 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_no_information_about_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..be539a0b79c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_standard_output_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_standard_output_feature.rs new file mode 100644 index 00000000000..fa37a139ce3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_standard_output_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_1_standard_output_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "pass_1 standard output"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_summary_feature.rs new file mode 100644 index 00000000000..52a4fa397e7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/outputs_the_successful_test_1_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_1_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "pass_1 ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/returns_success_feature.rs new file mode 100644 index 00000000000..8ded9955d32 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_1_of_2/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_1 --nocapture --exact", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/mod.rs new file mode 100644 index 00000000000..62b38432879 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/mod.rs @@ -0,0 +1,7 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_test_1_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_2_standard_output_feature; +mod outputs_the_successful_test_2_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..3f7878d1a5c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_error_feature.rs new file mode 100644 index 00000000000..9b772d22b36 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_information_about_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_information_about_test_1_feature.rs new file mode 100644 index 00000000000..4bb2a49e2d8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_no_information_about_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..8df859a7875 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_standard_output_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_standard_output_feature.rs new file mode 100644 index 00000000000..2492037d99d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_standard_output_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_2_standard_output_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "pass_2 standard output"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_summary_feature.rs new file mode 100644 index 00000000000..6fac684eb9b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/outputs_the_successful_test_2_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_2_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "pass_2 ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/returns_success_feature.rs new file mode 100644 index 00000000000..8e72c9616f2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/with_successful_test_match_2_of_2/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass_2 --nocapture --exact", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/mod.rs new file mode 100644 index 00000000000..c4cbfed6801 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_0_tests_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_test_1_feature; +mod outputs_no_information_about_test_2_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_its_running_0_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_its_running_0_tests_feature.rs new file mode 100644 index 00000000000..713f57894d6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_its_running_0_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_0_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_the_standard_output_should_have(&context, "running 0 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_error_feature.rs new file mode 100644 index 00000000000..70f4732e227 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_1_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_1_feature.rs new file mode 100644 index 00000000000..6e8d5664695 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_1_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_1_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_1"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_2_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_2_feature.rs new file mode 100644 index 00000000000..da48e3fa31e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_no_information_about_test_2_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_test_2_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_the_standard_output_should_not_have(&context, "pass_2"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..ee161447cb9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 2 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/returns_success_feature.rs new file mode 100644 index 00000000000..36872863399 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/__exact/without_test_match/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "boo --nocapture --exact", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/mod.rs new file mode 100644 index 00000000000..0e1da116ca2 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/__nocapture/mod.rs @@ -0,0 +1 @@ +mod __exact; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/mod.rs new file mode 100644 index 00000000000..60167028c54 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/mod.rs @@ -0,0 +1,6 @@ +mod with_one_full_match_successful_test; +mod with_one_partial_match_successful_test; +mod with_one_prefix_match_successful_test; +mod with_one_suffix_match_successful_test; +mod with_two_partial_match_successful_tests; +mod without_match_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..5d33c558159 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..a6f683e7755 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..d32ee62261a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..c97d519d350 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have(&context, "pass ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..58a0212e16e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_full_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..18e9536399f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "as", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..04bb065ffae --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "as", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..0415501f5e4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "as", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..0bad83c0c0a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "as", + ); + then_the_standard_output_should_have(&context, "pass ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..35297c6ad6a --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_partial_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "as", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..cefb96d00f0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pa", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..3fc2869a6f5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pa", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..cca01a57901 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pa", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..96940b741b3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pa", + ); + then_the_standard_output_should_have(&context, "pass ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..bb6c1dd8d0e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_prefix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pa", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..2cf820d064c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "ss", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..443ba658218 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "ss", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..0930884db7b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "ss", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..b30cc4449a6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "ss", + ); + then_the_standard_output_should_have(&context, "pass ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..d1ba66cf007 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_one_suffix_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "ss", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/mod.rs new file mode 100644 index 00000000000..914c3b09505 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_1_summary_feature; +mod outputs_the_successful_test_2_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..6f272c02c18 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..85c3e786f59 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..afc98691d63 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 2 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_1_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_1_summary_feature.rs new file mode 100644 index 00000000000..7656151feb9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_1_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_1_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have(&context, "pass_1 ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_2_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_2_summary_feature.rs new file mode 100644 index 00000000000..47ebd4ff09b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/outputs_the_successful_test_2_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_2_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_the_standard_output_should_have(&context, "pass_2 ... ok"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/returns_success_feature.rs new file mode 100644 index 00000000000..e9510645ab7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/with_two_partial_match_successful_tests/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_two_successful_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_two_successful_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "pass", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/mod.rs new file mode 100644 index 00000000000..eaa6fdd8f20 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_no_information_about_the_skipped_test_feature; +mod outputs_the_assembly_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..3487e70d3b9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "cool", + ); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..7d0f9305659 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "cool", + ); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs new file mode 100644 index 00000000000..eec9fe7ea1e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_no_information_about_the_skipped_test_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_not_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_no_information_about_the_skipped_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "cool", + ); + then_the_standard_output_should_not_have( + &context, + "test assembly_with_one_successful_test::pass", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..1adf56ef665 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,18 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "cool", + ); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 0 ignored; 1 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..57bee856988 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/default/without_match_successful_test/returns_success_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + &mut context, + "cool", + ); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/mod.rs new file mode 100644 index 00000000000..8520fe25bbc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/with_arguments/testname/mod.rs @@ -0,0 +1,2 @@ +mod __nocapture; +mod default; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/mod.rs new file mode 100644 index 00000000000..4ca47c84090 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/mod.rs @@ -0,0 +1,6 @@ +mod with_one_failing_test; +mod with_one_ignored_test; +mod with_one_ignored_with_reason_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/mod.rs new file mode 100644 index 00000000000..a1167f8d4ad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/mod.rs @@ -0,0 +1,6 @@ +mod outputs_its_running_1_test_feature; +mod outputs_the_assembly_failure_summary_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_failed_test_assertion_error_feature; +mod outputs_the_failed_test_summary_feature; +mod returns_failure_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..ccf6bb752af --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs new file mode 100644 index 00000000000..8313595e025 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_failure_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_failure_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "failures:\n\n assembly_with_one_failing_test::fail", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..b7de831ef1f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs new file mode 100644 index 00000000000..92288d2ee7f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_assertion_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_assertion_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_have( + &context, + "assertion `left == right` failed\n left: 1\n right: 2", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs new file mode 100644 index 00000000000..2bf1f5af8c9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/outputs_the_failed_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_failing_test::fail ... FAIL", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/returns_failure_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/returns_failure_feature.rs new file mode 100644 index 00000000000..47b417e76b6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_failing_test/returns_failure_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::error_code::then_failure_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_failure_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_failure_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..734c2b900dc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..3115ee423dd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..30a2e080493 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..a04301671f0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 1 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_ignored_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_ignored_test_summary_feature.rs new file mode 100644 index 00000000000..414682e57c7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/outputs_the_ignored_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_ignored_test::ignored ... ignored", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/returns_success_feature.rs new file mode 100644 index 00000000000..cf2c5530769 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/mod.rs new file mode 100644 index 00000000000..734c2b900dc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..7f088f8965b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..d005b7c3a40 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..5e924fdd808 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 0 passed; 0 failed; 1 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_summary_feature.rs new file mode 100644 index 00000000000..e01bb713910 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/outputs_the_ignored_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_ignored_with_reason_test::ignored ... ignored, test", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs new file mode 100644 index 00000000000..c0b2c36f344 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_ignored_with_reason_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_ignored_with_reason_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_ignored_with_reason_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..e4b0a4ed3f8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,7 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_the_assembly_failure_summary_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_failed_test_assertion_error_feature; +mod outputs_the_failed_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_failure_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..7672c61985e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs new file mode 100644 index 00000000000..756450cfcf0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_failure_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_failure_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "failures:\n\n assembly_with_one_successful_and_one_failing_tests::fail\n", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..3b9b9625dd6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: FAILED. 1 passed; 1 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs new file mode 100644 index 00000000000..7b5d304560f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_assertion_error_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_assertion_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_have( + &context, + "assertion `left == right` failed\n left: 1\n right: 2", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs new file mode 100644 index 00000000000..b6b903a7fcc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_failed_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_failed_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_failing_tests::fail ... FAIL", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..0f97c7d14d0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_failing_tests::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs new file mode 100644 index 00000000000..88a6a69d90b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_failing_tests/returns_failure_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_failing_tests; +use crate::__steps__::error_code::then_failure_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_failure_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_failing_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_failure_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..d9bddeea739 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_2_tests_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_ignored_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs new file mode 100644 index 00000000000..9ded9dcb74f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_its_running_2_tests_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_2_tests_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 2 tests"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..5d75b080472 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 1 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_summary_feature.rs new file mode 100644 index 00000000000..70459025bbe --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_ignored_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_ignored_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_ignored_tests::ignored ... ignored", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..eaa25c6f508 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_and_one_ignored_tests::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs new file mode 100644 index 00000000000..519e245e818 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_and_one_ignored_tests/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..bf861595afb --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..3c4a51bf5a8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..ac2e4599fa3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..0d26c5ed5f3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_test::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..2a4d9f053f3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_0/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/mod.rs new file mode 100644 index 00000000000..db99b0bac03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/mod.rs @@ -0,0 +1 @@ +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..f2ab09c3dd4 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..d2731e0289c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..280cc85469d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..a3fc69f402b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_level_1_test::level_1::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..0a0b83fcf3e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_1/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_1_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_1_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/mod.rs new file mode 100644 index 00000000000..db99b0bac03 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/mod.rs @@ -0,0 +1 @@ +mod with_one_successful_test; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..e47449a0ae8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/mod.rs @@ -0,0 +1,5 @@ +mod outputs_its_running_1_test_feature; +mod outputs_no_error_feature; +mod outputs_the_assembly_test_summary_feature; +mod outputs_the_successful_test_summary_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_its_running_1_test_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_its_running_1_test_feature.rs new file mode 100644 index 00000000000..44aaeaf603d --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_its_running_1_test_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_its_running_1_test_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "running 1 test"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_no_error_feature.rs new file mode 100644 index 00000000000..dc728576566 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_error_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs new file mode 100644 index 00000000000..55f90e0d0f8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_assembly_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_assembly_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test result: ok. 1 passed; 0 failed; 0 ignored; 0 filtered out", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_successful_test_summary_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_successful_test_summary_feature.rs new file mode 100644 index 00000000000..9c7a449c484 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/outputs_the_successful_test_summary_feature.rs @@ -0,0 +1,15 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_the_successful_test_summary_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have( + &context, + "test assembly_with_one_successful_level_2_test::level_1::level_2::pass ... ok", + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/returns_success_feature.rs new file mode 100644 index 00000000000..05a2aaded5f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/level_2/with_one_successful_test/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_successful_level_2_test; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_successful_level_2_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/mod.rs new file mode 100644 index 00000000000..a2590091967 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/mod.rs @@ -0,0 +1,4 @@ +mod level_0; +mod level_1; +mod level_2; +mod without_tests; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/mod.rs new file mode 100644 index 00000000000..ecb3f016be0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/mod.rs @@ -0,0 +1,3 @@ +mod outputs_no_error_feature; +mod outputs_no_tests_to_run_warning_feature; +mod returns_success_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_error_feature.rs new file mode 100644 index 00000000000..dbe3ba0d600 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_error_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_error::then_the_standard_error_should_be_empty; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_error_should_be_empty(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_tests_to_run_warning_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_tests_to_run_warning_feature.rs new file mode 100644 index 00000000000..be6a8a9ddc3 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/outputs_no_tests_to_run_warning_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::standard_output::then_the_standard_output_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn outputs_no_tests_to_run_warning_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_the_standard_output_should_have(&context, "no tests to run!"); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/returns_success_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/returns_success_feature.rs new file mode 100644 index 00000000000..448550aa7c9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/with_an_assembly/without_arguments/without_tests/returns_success_feature.rs @@ -0,0 +1,12 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_without_anything; +use crate::__steps__::success::then_success_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +use crate::__steps__::Context; + +#[test] +fn returns_success_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_without_anything(&mut context); + when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(&mut context); + then_success_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/mod.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/mod.rs new file mode 100644 index 00000000000..34fb4fe6ffa --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/mod.rs @@ -0,0 +1,3 @@ +mod outputs_invalid_arguments_error_feature; +mod outputs_the_wasm_bindgen_test_runner_usage_information_feature; +mod returns_failure_feature; diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_invalid_arguments_error_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_invalid_arguments_error_feature.rs new file mode 100644 index 00000000000..3c8ec44d914 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_invalid_arguments_error_feature.rs @@ -0,0 +1,10 @@ +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_without_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_test_file_missing_error_feature() { + let mut context = Context::new(); + when_wasm_bindgen_test_runner_is_invoked_without_arguments(&mut context); + then_the_standard_error_should_have(&context, "Invalid arguments."); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_the_wasm_bindgen_test_runner_usage_information_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_the_wasm_bindgen_test_runner_usage_information_feature.rs new file mode 100644 index 00000000000..a34615937dd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/outputs_the_wasm_bindgen_test_runner_usage_information_feature.rs @@ -0,0 +1,20 @@ +use crate::__steps__::assembly::given_there_is_an_assembly_with_one_failing_test; +use crate::__steps__::standard_error::then_the_standard_error_should_have; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_without_arguments; +use crate::__steps__::Context; + +#[test] +fn outputs_the_wasm_bindgen_test_runner_usage_information_feature() { + let mut context = Context::new(); + given_there_is_an_assembly_with_one_failing_test(&mut context); + when_wasm_bindgen_test_runner_is_invoked_without_arguments(&mut context); + then_the_standard_error_should_have( + &context, + r#"Usage: + wasm-bindgen-test-runner [options] [] [--include-ignored] [(--skip PATTERN)...] [--nocapture] + wasm-bindgen-test-runner [options] [--nocapture] --exact + wasm-bindgen-test-runner [options] --list [--format FORMAT] [--ignored] + wasm-bindgen-test-runner -h | --help + wasm-bindgen-test-runner -V | --version"#, + ); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/returns_failure_feature.rs b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/returns_failure_feature.rs new file mode 100644 index 00000000000..115af160f9b --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/invocation/without_arguments/returns_failure_feature.rs @@ -0,0 +1,10 @@ +use crate::__steps__::error_code::then_failure_should_have_been_returned; +use crate::__steps__::wasm_bindgen_test_runner::when_wasm_bindgen_test_runner_is_invoked_without_arguments; +use crate::__steps__::Context; + +#[test] +fn returns_an_error_code_feature() { + let mut context = Context::new(); + when_wasm_bindgen_test_runner_is_invoked_without_arguments(&mut context); + then_failure_should_have_been_returned(&context); +} diff --git a/tests/wasm_bindgen_test_runner/__features__/mod.rs b/tests/wasm_bindgen_test_runner/__features__/mod.rs new file mode 100644 index 00000000000..2f054bc37a7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__features__/mod.rs @@ -0,0 +1 @@ +mod invocation; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/assembly_builder.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/assembly_builder.rs new file mode 100644 index 00000000000..f5b6dedc158 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/assembly_builder.rs @@ -0,0 +1,108 @@ +use predicates::str; +use regex::Regex; +use std::env; +use std::fs; +use std::path::PathBuf; +use std::process::Command; +use std::process::Output; + +fn target_dir() -> PathBuf { + let mut dir = env::current_exe().unwrap(); + dir.pop(); // current exe + if dir.ends_with("deps") { + dir.pop(); + } + dir.pop(); // debug and/or release + dir +} + +fn repo_root() -> PathBuf { + env::current_dir().unwrap() +} + +pub struct AssemblyBuilder { + root: PathBuf, + name: String, +} + +impl AssemblyBuilder { + pub fn new(name: &'static str) -> AssemblyBuilder { + let root = target_dir() + .join("wasm-bindgen-test-runner-tests") + .join(name); + drop(fs::remove_dir_all(&root)); + fs::create_dir_all(&root).unwrap(); + AssemblyBuilder { + root, + name: name.to_string(), + } + } + + pub fn clean(&mut self) { + drop(fs::remove_dir_all(&self.root)); + } + + pub fn file(&mut self, name: &str, contents: &str) -> &mut Self { + let dst = self.root.join(name); + fs::create_dir_all(dst.parent().unwrap()).unwrap(); + fs::write(&dst, contents).unwrap(); + self + } + + pub fn build(&mut self) -> PathBuf { + if !self.root.join("Cargo.toml").is_file() { + self.file( + "Cargo.toml", + &format!( + "[package] +name = '{}' +authors = [] +version = '1.0.0' +edition = '2021' + +[dev-dependencies] +wasm-bindgen-test = {{ path = '{}/crates/test' }} + +[patch.crates-io] +wasm-bindgen = {{ path = '{}' }} + +[workspace] +", + self.name, + repo_root().display(), + repo_root().display(), + ), + ); + } + + let output = Command::new("cargo") + .current_dir(&self.root) + .arg("test") + .arg("--target") + .arg("wasm32-unknown-unknown") + .arg("--no-run") + .env("CARGO_TARGET_DIR", target_dir()) + .output() + .expect("Failed to build test assembly"); + + let assembly = extract_assembly_from_output(output); + + self.root.join(assembly) + } +} + +fn extract_assembly_from_output(output: Output) -> String { + let error_str = std::str::from_utf8(&output.stderr).unwrap(); + let last = error_str.lines().last().unwrap(); + + if last.starts_with("error") { + panic!("Failed to generate assembly\n{}", error_str); + } + + let re = Regex::new(r"\((.*?)\)").unwrap(); + let captures = re + .captures(last) + .expect(&format!("Failed to generate assembly\n{}", error_str)); + + captures.get(1).unwrap().as_str().to_string() +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_with_one_failing_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_with_one_failing_test.rs new file mode 100644 index 00000000000..71bb1ec4739 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_with_one_failing_test.rs @@ -0,0 +1,26 @@ +use super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_one_failing_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +fn fail() { + assert_eq!(1, 2); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_failing_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_without_anything.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_without_anything.rs new file mode 100644 index 00000000000..29c62d35c0c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/given_there_is_an_assembly_without_anything.rs @@ -0,0 +1,19 @@ +use super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_without_anything") + .file( + "src/lib.rs", + r#" + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_without_anything(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/mod.rs new file mode 100644 index 00000000000..fe6804e6949 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/mod.rs @@ -0,0 +1,19 @@ +mod assembly_builder; +mod given_there_is_an_assembly_with_one_failing_test; +mod given_there_is_an_assembly_without_anything; +mod with_one_ignored_test; +mod with_one_ignored_with_reason_test; +mod with_one_successful_and_one_failing_tests; +mod with_one_successful_and_one_ignored_tests; +mod with_one_successful_test; +mod with_two_successful_tests; + +pub use assembly_builder::*; +pub use given_there_is_an_assembly_with_one_failing_test::*; +pub use given_there_is_an_assembly_without_anything::*; +pub use with_one_ignored_test::*; +pub use with_one_ignored_with_reason_test::*; +pub use with_one_successful_and_one_failing_tests::*; +pub use with_one_successful_and_one_ignored_tests::*; +pub use with_one_successful_test::*; +pub use with_two_successful_tests::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_1_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_1_test.rs new file mode 100644 index 00000000000..de03a351601 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_1_test.rs @@ -0,0 +1,29 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_one_ignored_level_1_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + #[ignore] + fn ignored() { + assert_eq!(1, 1); + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_ignored_level_1_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_2_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_2_test.rs new file mode 100644 index 00000000000..1ea33e3ccff --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_level_2_test.rs @@ -0,0 +1,31 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_one_ignored_level_2_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + mod level_2 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + #[ignore] + fn ignored() { + assert_eq!(1, 1); + } + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_ignored_level_2_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_test.rs new file mode 100644 index 00000000000..f0725eed341 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/given_there_is_an_assembly_with_one_ignored_test.rs @@ -0,0 +1,27 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_one_ignored_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +#[ignore] +fn ignored() { + assert_eq!(1, 1); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_ignored_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/mod.rs new file mode 100644 index 00000000000..d2d4828016c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_test/mod.rs @@ -0,0 +1,7 @@ +mod given_there_is_an_assembly_with_one_ignored_level_1_test; +mod given_there_is_an_assembly_with_one_ignored_level_2_test; +mod given_there_is_an_assembly_with_one_ignored_test; + +pub use given_there_is_an_assembly_with_one_ignored_level_1_test::*; +pub use given_there_is_an_assembly_with_one_ignored_level_2_test::*; +pub use given_there_is_an_assembly_with_one_ignored_test::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/given_there_is_an_assembly_with_one_ignored_with_reason_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/given_there_is_an_assembly_with_one_ignored_with_reason_test.rs new file mode 100644 index 00000000000..74b254cf545 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/given_there_is_an_assembly_with_one_ignored_with_reason_test.rs @@ -0,0 +1,28 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_ignored_with_reason_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +#[ignore = "test"] +fn ignored() { + assert_eq!(1, 1); +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_ignored_with_reason_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/mod.rs new file mode 100644 index 00000000000..7b6014d0a67 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_ignored_with_reason_test/mod.rs @@ -0,0 +1,3 @@ +mod given_there_is_an_assembly_with_one_ignored_with_reason_test; + +pub use given_there_is_an_assembly_with_one_ignored_with_reason_test::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests.rs new file mode 100644 index 00000000000..704af5a9845 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests.rs @@ -0,0 +1,37 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_failing_level_1_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } + + #[cfg(test)] + #[wasm_bindgen_test] + fn fail() { + assert_eq!(1, 2); + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests( + context: &mut Context, +) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests.rs new file mode 100644 index 00000000000..70c5f1db6fe --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests.rs @@ -0,0 +1,39 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_failing_level_2_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + mod level_2 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } + + #[cfg(test)] + #[wasm_bindgen_test] + fn fail() { + assert_eq!(1, 2); + } + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests( + context: &mut Context, +) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_tests.rs new file mode 100644 index 00000000000..f51601b4519 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/given_there_is_an_assembly_with_one_successful_and_one_failing_tests.rs @@ -0,0 +1,33 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_failing_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +fn pass() { + assert_eq!(1, 1); +} + +#[cfg(test)] +#[wasm_bindgen_test] +fn fail() { + assert_eq!(1, 2); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_failing_tests(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/mod.rs new file mode 100644 index 00000000000..77684ffda47 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_failing_tests/mod.rs @@ -0,0 +1,7 @@ +mod given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests; +mod given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests; +mod given_there_is_an_assembly_with_one_successful_and_one_failing_tests; + +pub use given_there_is_an_assembly_with_one_successful_and_one_failing_level_1_tests::*; +pub use given_there_is_an_assembly_with_one_successful_and_one_failing_level_2_tests::*; +pub use given_there_is_an_assembly_with_one_successful_and_one_failing_tests::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests.rs new file mode 100644 index 00000000000..88f6b20699c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests.rs @@ -0,0 +1,38 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_ignored_level_1_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } + + #[cfg(test)] + #[wasm_bindgen_test] + #[ignore] + fn ignored() { + assert_eq!(1, 1); + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests( + context: &mut Context, +) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests.rs new file mode 100644 index 00000000000..522eec9e6ea --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests.rs @@ -0,0 +1,40 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_ignored_level_2_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + mod level_2 { + use wasm_bindgen_test::*; + + #[cfg(test)] + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } + + #[cfg(test)] + #[wasm_bindgen_test] + #[ignore] + fn ignored() { + assert_eq!(1, 1); + } + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests( + context: &mut Context, +) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_tests.rs new file mode 100644 index 00000000000..32c6d56ec02 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/given_there_is_an_assembly_with_one_successful_and_one_ignored_tests.rs @@ -0,0 +1,34 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_and_one_ignored_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +fn pass() { + assert_eq!(1, 1); +} + +#[cfg(test)] +#[wasm_bindgen_test] +#[ignore] +fn ignored() { + assert_eq!(1, 1); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_and_one_ignored_tests(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/mod.rs new file mode 100644 index 00000000000..7fa39772d42 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_and_one_ignored_tests/mod.rs @@ -0,0 +1,7 @@ +mod given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests; +mod given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests; +mod given_there_is_an_assembly_with_one_successful_and_one_ignored_tests; + +pub use given_there_is_an_assembly_with_one_successful_and_one_ignored_level_1_tests::*; +pub use given_there_is_an_assembly_with_one_successful_and_one_ignored_level_2_tests::*; +pub use given_there_is_an_assembly_with_one_successful_and_one_ignored_tests::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_1_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_1_test.rs new file mode 100644 index 00000000000..a5284f95613 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_1_test.rs @@ -0,0 +1,27 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_level_1_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + use wasm_bindgen_test::*; + + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } +}"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_level_1_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_2_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_2_test.rs new file mode 100644 index 00000000000..03ad4f702c9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_level_2_test.rs @@ -0,0 +1,29 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_one_successful_level_2_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + mod level_2 { + use wasm_bindgen_test::*; + + #[wasm_bindgen_test] + fn pass() { + assert_eq!(1, 1); + } + } +}"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_level_2_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_test.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_test.rs new file mode 100644 index 00000000000..828c62468c6 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/given_there_is_an_assembly_with_one_successful_test.rs @@ -0,0 +1,26 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_one_successful_test") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +fn pass() { + assert_eq!(1, 1); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_one_successful_test(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/mod.rs new file mode 100644 index 00000000000..8f177fd5ba5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_one_successful_test/mod.rs @@ -0,0 +1,7 @@ +mod given_there_is_an_assembly_with_one_successful_level_1_test; +mod given_there_is_an_assembly_with_one_successful_level_2_test; +mod given_there_is_an_assembly_with_one_successful_test; + +pub use given_there_is_an_assembly_with_one_successful_level_1_test::*; +pub use given_there_is_an_assembly_with_one_successful_level_2_test::*; +pub use given_there_is_an_assembly_with_one_successful_test::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_level_1_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_level_1_tests.rs new file mode 100644 index 00000000000..8cffd90fe1f --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_level_1_tests.rs @@ -0,0 +1,35 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = + AssemblyBuilder::new("assembly_with_two_successful_level_1_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +mod level_1 { + use wasm_bindgen_test::*; + + #[wasm_bindgen_test] + fn pass_1() { + console_log!("pass_1 standard output"); + assert_eq!(1, 1); + } + + #[wasm_bindgen_test] + fn pass_2() { + console_log!("pass_2 standard output"); + assert_eq!(1, 1); + } +} +"#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_two_successful_level_1_tests(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_tests.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_tests.rs new file mode 100644 index 00000000000..1345304be28 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/given_there_is_an_assembly_with_two_successful_tests.rs @@ -0,0 +1,34 @@ +use super::super::AssemblyBuilder; +use crate::__steps__::wasm_bindgen_test_runner::Sandbox; +use crate::__steps__::Context; +use lazy_static::lazy_static; +use std::path::PathBuf; + +lazy_static! { + static ref ASSEMBLY: PathBuf = AssemblyBuilder::new("assembly_with_two_successful_tests") + .file( + "src/lib.rs", + r#"#[cfg(test)] +use wasm_bindgen_test::*; + +#[cfg(test)] +#[wasm_bindgen_test] +fn pass_1() { + console_log!("pass_1 standard output"); + assert_eq!(1, 1); +} + +#[cfg(test)] +#[wasm_bindgen_test] +fn pass_2() { + console_log!("pass_2 standard output"); + assert_eq!(1, 1); +} + "#, + ) + .build(); +} + +pub fn given_there_is_an_assembly_with_two_successful_tests(context: &mut Context) { + context.sandbox_set(Sandbox::new(ASSEMBLY.clone())); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/mod.rs new file mode 100644 index 00000000000..ec713148ddc --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/assembly/with_two_successful_tests/mod.rs @@ -0,0 +1,5 @@ +mod given_there_is_an_assembly_with_two_successful_level_1_tests; +mod given_there_is_an_assembly_with_two_successful_tests; + +pub use given_there_is_an_assembly_with_two_successful_level_1_tests::*; +pub use given_there_is_an_assembly_with_two_successful_tests::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/context.rs b/tests/wasm_bindgen_test_runner/__steps__/context.rs new file mode 100644 index 00000000000..41311b4caa5 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/context.rs @@ -0,0 +1,36 @@ +use super::wasm_bindgen_test_runner::Sandbox; +use std::process::Output; + +pub struct Context { + output: Option>, + sandbox: Option, +} + +impl Context { + pub fn new() -> Self { + Context { + output: None, + sandbox: None, + } + } + + pub fn output(&self) -> Result { + Ok(self.output.as_ref().unwrap().as_ref()?.clone()) + } + + pub fn output_set(&mut self, output: Result) { + self.output = Some(output); + } + + pub fn sandbox(&self) -> &Sandbox { + self.sandbox.as_ref().unwrap() + } + + pub fn sandbox_mut(&mut self) -> &mut Sandbox { + self.sandbox.as_mut().unwrap() + } + + pub fn sandbox_set(&mut self, sandbox: Sandbox) { + self.sandbox = Some(sandbox); + } +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/error_code/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/error_code/mod.rs new file mode 100644 index 00000000000..f1df5dc51ad --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/error_code/mod.rs @@ -0,0 +1,3 @@ +mod then_failure_should_have_been_returned; + +pub use then_failure_should_have_been_returned::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/error_code/then_failure_should_have_been_returned.rs b/tests/wasm_bindgen_test_runner/__steps__/error_code/then_failure_should_have_been_returned.rs new file mode 100644 index 00000000000..c8a66cf273c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/error_code/then_failure_should_have_been_returned.rs @@ -0,0 +1,8 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; + +pub fn then_failure_should_have_been_returned(context: &Context) { + let output = context.output().expect("No output was produced"); + + output.assert().failure(); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/mod.rs new file mode 100644 index 00000000000..1f0114f0740 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/mod.rs @@ -0,0 +1,9 @@ +pub mod assembly; +mod context; +pub mod error_code; +pub mod standard_error; +pub mod standard_output; +pub mod success; +pub mod wasm_bindgen_test_runner; + +pub use context::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_error/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_error/mod.rs new file mode 100644 index 00000000000..14c7d5b9c66 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_error/mod.rs @@ -0,0 +1,5 @@ +mod then_the_standard_error_should_be_empty; +mod then_the_standard_error_should_have; + +pub use then_the_standard_error_should_be_empty::*; +pub use then_the_standard_error_should_have::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_be_empty.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_be_empty.rs new file mode 100644 index 00000000000..846c88b0084 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_be_empty.rs @@ -0,0 +1,9 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; +use predicates::str; + +pub fn then_the_standard_error_should_be_empty(context: &Context) { + let output = context.output().expect("No output was produced"); + + output.assert().stderr(str::is_empty()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_have.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_have.rs new file mode 100644 index 00000000000..b8de94dc6ab --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_error/then_the_standard_error_should_have.rs @@ -0,0 +1,9 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; +use predicates::str; + +pub fn then_the_standard_error_should_have(context: &Context, content: &str) { + let output = context.output().expect("No output was produced"); + + output.assert().stderr(str::contains(content)); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_output/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_output/mod.rs new file mode 100644 index 00000000000..e26bc7df85e --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_output/mod.rs @@ -0,0 +1,7 @@ +mod then_the_standard_output_should_be_empty; +mod then_the_standard_output_should_have; +mod then_the_standard_output_should_not_have; + +pub use then_the_standard_output_should_be_empty::*; +pub use then_the_standard_output_should_have::*; +pub use then_the_standard_output_should_not_have::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_be_empty.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_be_empty.rs new file mode 100644 index 00000000000..57074eea6a8 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_be_empty.rs @@ -0,0 +1,9 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; +use predicates::str; + +pub fn then_the_standard_output_should_be_empty(context: &Context) { + let output = context.output().expect("No output was produced"); + + output.assert().stdout(str::is_empty()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_have.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_have.rs new file mode 100644 index 00000000000..ec21c468b96 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_have.rs @@ -0,0 +1,9 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; +use predicates::str; + +pub fn then_the_standard_output_should_have(context: &Context, content: &str) { + let output = context.output().expect("No output was produced"); + + output.assert().stdout(str::contains(content)); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_not_have.rs b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_not_have.rs new file mode 100644 index 00000000000..9ecd7a5a096 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/standard_output/then_the_standard_output_should_not_have.rs @@ -0,0 +1,10 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; +use predicates::boolean::PredicateBooleanExt; +use predicates::str; + +pub fn then_the_standard_output_should_not_have(context: &Context, content: &str) { + let output = context.output().expect("No output was produced"); + + output.assert().stdout(str::contains(content).not()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/success/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/success/mod.rs new file mode 100644 index 00000000000..a0461886d72 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/success/mod.rs @@ -0,0 +1,3 @@ +mod then_success_should_have_been_returned; + +pub use then_success_should_have_been_returned::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/success/then_success_should_have_been_returned.rs b/tests/wasm_bindgen_test_runner/__steps__/success/then_success_should_have_been_returned.rs new file mode 100644 index 00000000000..4b62def3181 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/success/then_success_should_have_been_returned.rs @@ -0,0 +1,8 @@ +use crate::__steps__::Context; +use assert_cmd::prelude::*; + +pub fn then_success_should_have_been_returned(context: &Context) { + let output = context.output().expect("No output was produced"); + + output.assert().success(); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/mod.rs new file mode 100644 index 00000000000..ef6cfe81bac --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/mod.rs @@ -0,0 +1,3 @@ +mod when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno; + +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno.rs new file mode 100644 index 00000000000..3cb17e9753c --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/deno/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno.rs @@ -0,0 +1,13 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_deno( + context: &mut Context, +) { + let mut command = wasm_bindgen_test_runner_command(); + + command.env("WASM_BINDGEN_USE_DENO", "true"); + + command.arg(context.sandbox_mut().assembly()); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/mod.rs new file mode 100644 index 00000000000..f7e012ba261 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/mod.rs @@ -0,0 +1,3 @@ +mod when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox; + +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox.rs new file mode 100644 index 00000000000..41cd924d0f7 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/firefox/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox.rs @@ -0,0 +1,13 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_firefox( + context: &mut Context, +) { + let mut command = wasm_bindgen_test_runner_command(); + + command.env("WASM_BINDGEN_USE_BROWSER", "firefox"); + + command.arg(context.sandbox_mut().assembly()); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/mod.rs new file mode 100644 index 00000000000..3c0e5a4a804 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/mod.rs @@ -0,0 +1,19 @@ +mod deno; +mod firefox; +mod node; +mod sandbox; +mod wasm_bindgen_test_runner_command; +mod when_wasm_bindgen_test_runner_is_invoked_with_the_assembly; +mod when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments; +mod when_wasm_bindgen_test_runner_is_invoked_with_the_option; +mod when_wasm_bindgen_test_runner_is_invoked_without_arguments; + +pub use deno::*; +pub use firefox::*; +pub use node::*; +pub use sandbox::*; +pub use wasm_bindgen_test_runner_command::*; +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_assembly::*; +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments::*; +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_option::*; +pub use when_wasm_bindgen_test_runner_is_invoked_without_arguments::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/mod.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/mod.rs new file mode 100644 index 00000000000..d9fa70b23a9 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/mod.rs @@ -0,0 +1,3 @@ +mod when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node; + +pub use when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node::*; diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node.rs new file mode 100644 index 00000000000..aa5e66a2f09 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/node/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node.rs @@ -0,0 +1,13 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_targeting_node( + context: &mut Context, +) { + let mut command = wasm_bindgen_test_runner_command(); + + command.env("WASM_BINDGEN_TEST_ONLY_NODE", "true"); + + command.arg(context.sandbox_mut().assembly()); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/sandbox.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/sandbox.rs new file mode 100644 index 00000000000..b637e3dc5b0 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/sandbox.rs @@ -0,0 +1,80 @@ +use rand::Rng; +use std::fs; +use std::path::PathBuf; + +pub struct Sandbox { + assembly: Option, + original: PathBuf, + root: Option, +} + +impl Sandbox { + pub fn new(original: PathBuf) -> Self { + if !&original.exists() { + panic!("Couldn't find generated assembly: {}", &original.display()); + } + Self { + assembly: None, + original, + root: None, + } + } + + fn init(&mut self) { + let file_name = self.original.file_name().and_then(|s| s.to_str()).unwrap(); + + let mut rng = rand::thread_rng(); + + let root = self + .original + .parent() // chop off file name + .and_then(|p| p.parent()) // chop off `deps` + .and_then(|p| p.parent()) // chop off `debug` + .and_then(|p| p.parent()) // chop off `wasm32-unknown-unknown` + .map(|p| p.join("wasm-bindgen-test-runner-tests")) + .map(|p| { + p.join(format!( + "sandbox-{}-{}", + file_name, + rng.gen_range(1000..9999) + )) + }) + .unwrap(); + + drop(fs::remove_dir_all(&root)); + + let target = root.join("debug").join("deps"); + + fs::create_dir_all(&target).unwrap(); + + let assembly = target.join(file_name); + + fs::copy(&self.original, &assembly).unwrap(); + + self.assembly = Some(assembly); + self.root = Some(root); + } + + pub fn assembly(&mut self) -> &PathBuf { + if self.assembly.is_none() { + self.init(); + } + self.assembly.as_ref().unwrap() + } + + pub fn original(&self) -> &PathBuf { + &self.original + } + + pub fn root(&self) -> &PathBuf { + self.root.as_ref().unwrap() + } +} + +impl Drop for Sandbox { + fn drop(&mut self) { + if let Some(root) = &self.root { + drop(fs::remove_dir_all(root)); + } + } +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/wasm_bindgen_test_runner_command.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/wasm_bindgen_test_runner_command.rs new file mode 100644 index 00000000000..0430fa19bfd --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/wasm_bindgen_test_runner_command.rs @@ -0,0 +1,28 @@ +use assert_cmd::cargo::{CargoError, CommandCargoExt}; +use lazy_static::lazy_static; +use std::process::Command; + +lazy_static! { + static ref COMMAND: Result = wasm_bindgen_test_runner_command_get(); +} + +fn wasm_bindgen_test_runner_command_get() -> Result { + let result = Command::cargo_bin("wasm-bindgen-test-runner"); + if result.is_ok() { + return result; + } + + Command::new("cargo") + .args(&["build", "--package", "wasm-bindgen-cli"]) + .output() + .expect("Failed to build wasm-bindgen-cli"); + + Command::cargo_bin("wasm-bindgen-test-runner") +} + +pub fn wasm_bindgen_test_runner_command() -> Command { + if COMMAND.is_ok() { + return Command::cargo_bin("wasm-bindgen-test-runner").unwrap(); + } + panic!("Failed to find wasm-bindgen-test-runner binary") +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly.rs new file mode 100644 index 00000000000..07e6d2d1632 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly.rs @@ -0,0 +1,9 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_assembly(context: &mut Context) { + let mut command = wasm_bindgen_test_runner_command(); + + command.arg(context.sandbox_mut().assembly()); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments.rs new file mode 100644 index 00000000000..4dc789f8904 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments.rs @@ -0,0 +1,18 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_assembly_and_the_arguments( + context: &mut Context, + arguments: &str, +) { + let mut command = wasm_bindgen_test_runner_command(); + + if arguments.starts_with("--list") && arguments.contains("--ignored") { + command.arg(context.sandbox().original()); + } else { + command.arg(context.sandbox_mut().assembly()); + } + + command.args(arguments.split_whitespace()); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_option.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_option.rs new file mode 100644 index 00000000000..45fda809441 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_with_the_option.rs @@ -0,0 +1,12 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_with_the_option( + context: &mut Context, + argument: &str, +) { + let mut command = wasm_bindgen_test_runner_command(); + + command.arg(argument); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_without_arguments.rs b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_without_arguments.rs new file mode 100644 index 00000000000..1a41de36274 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/__steps__/wasm_bindgen_test_runner/when_wasm_bindgen_test_runner_is_invoked_without_arguments.rs @@ -0,0 +1,7 @@ +use crate::__steps__::{wasm_bindgen_test_runner::wasm_bindgen_test_runner_command, Context}; + +pub fn when_wasm_bindgen_test_runner_is_invoked_without_arguments(context: &mut Context) { + let mut command = wasm_bindgen_test_runner_command(); + + context.output_set(command.output()); +} diff --git a/tests/wasm_bindgen_test_runner/main.rs b/tests/wasm_bindgen_test_runner/main.rs new file mode 100644 index 00000000000..4adc5c045a1 --- /dev/null +++ b/tests/wasm_bindgen_test_runner/main.rs @@ -0,0 +1,3 @@ +#![cfg(not(target_arch = "wasm32"))] +mod __features__; +mod __steps__;