From eba678b6ded6084ffc23920b82d824fb8fe47f13 Mon Sep 17 00:00:00 2001 From: Aravinth Manivannan Date: Fri, 17 May 2024 23:27:33 +0530 Subject: [PATCH] feat: BDD test helpers --- src/tests/bdd.rs | 11 +++++++++++ src/tests/mod.rs | 5 +++++ 2 files changed, 16 insertions(+) create mode 100644 src/tests/bdd.rs create mode 100644 src/tests/mod.rs diff --git a/src/tests/bdd.rs b/src/tests/bdd.rs new file mode 100644 index 0000000..ed12203 --- /dev/null +++ b/src/tests/bdd.rs @@ -0,0 +1,11 @@ +// SPDX-FileCopyrightText: 2024 Aravinth Manivannan +// +// SPDX-License-Identifier: AGPL-3.0-or-later + +pub const IS_CALLED_ONLY_ONCE: Option = Some(1); +pub const IS_NEVER_CALLED: Option = None; +pub const IS_CALLED_ONLY_TWICE: Option = Some(2); +pub const RETURNS_RANDOM_STRING: &str = "test_random_string"; + +pub const RETURNS_TRUE: bool = true; +pub const RETURNS_FALSE: bool = false; diff --git a/src/tests/mod.rs b/src/tests/mod.rs new file mode 100644 index 0000000..e799cc5 --- /dev/null +++ b/src/tests/mod.rs @@ -0,0 +1,5 @@ +// SPDX-FileCopyrightText: 2024 Aravinth Manivannan +// +// SPDX-License-Identifier: AGPL-3.0-or-later + +pub mod bdd;