Minor refactorings, justfile tweaks, roadmap update
This commit is contained in:
parent
bfd22bb6fa
commit
79c0ba9eed
5 changed files with 16 additions and 18 deletions
|
|
@ -180,19 +180,13 @@ mod tests {
|
|||
|
||||
#[test]
|
||||
fn detached_node() {
|
||||
let node = Node {
|
||||
id: String::from("SomeNode"),
|
||||
text: String::new(),
|
||||
title: String::new(),
|
||||
links: vec![String::new()],
|
||||
hidden: false,
|
||||
connections: Some(vec![Edge {
|
||||
anchor: String::from("SomeAnchor"),
|
||||
from: String::new(),
|
||||
to: String::new(),
|
||||
detached: false,
|
||||
}]),
|
||||
};
|
||||
let mut node = Node::new(None);
|
||||
node.connections = Some(vec![Edge {
|
||||
anchor: String::from("SomeAnchor"),
|
||||
from: String::new(),
|
||||
to: String::new(),
|
||||
detached: false,
|
||||
}]);
|
||||
|
||||
let mut map: HashMap<String, Node> = HashMap::new();
|
||||
map.insert(String::from("SomeNode"), node);
|
||||
|
|
|
|||
|
|
@ -147,8 +147,8 @@ impl Graph {
|
|||
impl Node {
|
||||
pub fn new(message: Option<String>) -> Node {
|
||||
Node {
|
||||
id: "VoidNode".to_string(),
|
||||
title: "Pure Void".to_string(),
|
||||
id: "404".to_string(),
|
||||
title: "Not Found".to_string(),
|
||||
text: match message {
|
||||
Some(s) => s,
|
||||
None => "Node is empty, missing or wasn't found.".to_string(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue