MCPcopy Index your code
hub / github.com/endbasic/endbasic / test_gpio_write_errors

Function test_gpio_write_errors

std/src/gpio/mod.rs:618–636  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

616
617 #[test]
618 fn test_gpio_write_errors() {
619 check_stmt_compilation_err("1:1: GPIO_WRITE expected pin%, value?", r#"GPIO_WRITE"#);
620 check_stmt_compilation_err("1:1: GPIO_WRITE expected pin%, value?", r#"GPIO_WRITE 2,"#);
621 check_stmt_compilation_err(
622 "1:1: GPIO_WRITE expected pin%, value?",
623 r#"GPIO_WRITE 1, TRUE, 2"#,
624 );
625 check_stmt_compilation_err(
626 "1:13: GPIO_WRITE expected pin%, value?",
627 r#"GPIO_WRITE 1; TRUE"#,
628 );
629
630 check_pin_validation("1:12: ", "1:12: ", r#"GPIO_WRITE _PIN_, TRUE"#);
631
632 check_stmt_compilation_err(
633 "1:15: Expected BOOLEAN but found INTEGER",
634 r#"GPIO_WRITE 1, 5"#,
635 );
636 }
637}

Callers

nothing calls this directly

Calls 2

check_pin_validationFunction · 0.85

Tested by

no test coverage detected