MCPcopy Create free account
hub / github.com/Notgnoshi/generative / test_smooth_unit_square

Function test_smooth_unit_square

tests/test_smooth.rs:6–20  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4
5#[test]
6fn test_smooth_unit_square() {
7 let input = b"POLYGON ((0 0, 0 1, 1 1, 1 0, 0 0))\n";
8
9 let expected = "\
10 POLYGON((0 0.25,0 0.75,0.25 1,0.75 1,1 0.75,1 0.25,0.75 0,0.25 0,0 0.25))\n\
11 ";
12
13 let output = tool("smooth")
14 .arg("--iterations=1")
15 .write_stdin(input)
16 .captured_output();
17 assert!(output.status.success());
18 let stdout = String::from_utf8_lossy(&output.stdout);
19 assert_eq!(expected, stdout);
20}

Callers

nothing calls this directly

Calls 2

toolFunction · 0.85
captured_outputMethod · 0.80

Tested by

no test coverage detected