From dc2ac943457c44e1d15c90aca7acbe9d4261e06b Mon Sep 17 00:00:00 2001 From: kjuulh Date: Mon, 2 Oct 2023 21:58:56 +0200 Subject: [PATCH] feat: with postgres Signed-off-by: kjuulh --- crates/crunch-postgres/Cargo.toml | 8 ++++++++ crates/crunch-postgres/src/lib.rs | 14 ++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 crates/crunch-postgres/Cargo.toml create mode 100644 crates/crunch-postgres/src/lib.rs diff --git a/crates/crunch-postgres/Cargo.toml b/crates/crunch-postgres/Cargo.toml new file mode 100644 index 0000000..7c9d190 --- /dev/null +++ b/crates/crunch-postgres/Cargo.toml @@ -0,0 +1,8 @@ +[package] +name = "crunch-postgres" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] diff --git a/crates/crunch-postgres/src/lib.rs b/crates/crunch-postgres/src/lib.rs new file mode 100644 index 0000000..7d12d9a --- /dev/null +++ b/crates/crunch-postgres/src/lib.rs @@ -0,0 +1,14 @@ +pub fn add(left: usize, right: usize) -> usize { + left + right +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn it_works() { + let result = add(2, 2); + assert_eq!(result, 4); + } +}