Browse Source

add empty library crate

main
xenua 1 year ago
parent
commit
abe8a46bbd
Signed by: xenua
GPG Key ID: 8F93B68BD37255B8
  1. 2
      .gitignore
  2. 8
      Cargo.toml
  3. 14
      src/lib.rs

2
.gitignore vendored

@ -0,0 +1,2 @@ @@ -0,0 +1,2 @@
/target
/Cargo.lock

8
Cargo.toml

@ -0,0 +1,8 @@ @@ -0,0 +1,8 @@
[package]
name = "child_repo"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]

14
src/lib.rs

@ -0,0 +1,14 @@ @@ -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);
}
}
Loading…
Cancel
Save