MCPcopy Create free account
hub / github.com/bytecodealliance/wit-bindgen / simple_append

Function simple_append

crates/core/src/source.rs:178–190  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

176
177 #[test]
178 fn simple_append() {
179 let mut s = Source::default();
180 s.push_str("x");
181 assert_eq!(s.s, "x");
182 s.push_str("y");
183 assert_eq!(s.s, "xy");
184 s.push_str("z ");
185 assert_eq!(s.s, "xyz ");
186 s.push_str(" a ");
187 assert_eq!(s.s, "xyz a ");
188 s.push_str("\na");
189 assert_eq!(s.s, "xyz a \na");
190 }
191
192 #[test]
193 fn newline_remap() {

Callers

nothing calls this directly

Calls 1

push_strMethod · 0.45

Tested by

no test coverage detected