Structure

This commit is contained in:
2023-01-16 19:04:11 -08:00
parent d968b34702
commit 3489b66ed6
7 changed files with 68 additions and 6 deletions

13
node/Cargo.toml Normal file
View File

@ -0,0 +1,13 @@
[package]
name = "physical-node"
description = "A node hosts peripherals."
version.workspace = true
edition.workspace = true
repository.workspace = true
readme.workspace = true
license.workspace = true
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
physical = { path = ".." }

14
node/src/lib.rs Normal file
View File

@ -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);
}
}