MCPcopy Create free account
hub / github.com/chirpstack/chirpstack / test_encode_timeout

Function test_encode_timeout

chirpstack/src/codec/js/mod.rs:345–363  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

343
344 #[tokio::test]
345 pub async fn test_encode_timeout() {
346 let encoder = r#"
347 function encodeDownlink(input) {
348 while (true) {
349
350 }
351 }
352 "#
353 .to_string();
354
355 let vars: HashMap<String, String> = HashMap::new();
356
357 let input = prost_types::Struct {
358 ..Default::default()
359 };
360
361 let out = encode(10, &vars, &encoder, &input).await;
362 assert!(out.is_err());
363 }
364
365 #[tokio::test]
366 pub async fn test_encode_error() {

Callers

nothing calls this directly

Calls 2

to_stringMethod · 0.80
encodeFunction · 0.70

Tested by

no test coverage detected