MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / parse

Function parse

src/repr/src/bytes.rs:247–249  ·  view source on GitHub ↗

shortcut for writing test cases

(s: &str)

Source from the content-addressed store, hash-verified

245 fn test_parse() {
246 // shortcut for writing test cases
247 fn parse(s: &str) -> ByteSize {
248 s.parse::<ByteSize>().unwrap()
249 }
250
251 assert_eq!(parse("0"), ByteSize::b(0));
252 assert_eq!(parse("9.9"), ByteSize::b(10));

Callers 1

parse_timestamp_stringFunction · 0.70

Calls 1

unwrapMethod · 0.80

Tested by

no test coverage detected