Fix encode/decode todo's (#13683)

Mistakes have been made. I forgot about a bunch of `todo`s in the helper
functions. So, this PR replaces them with proper errors. It also adds
tests for parse-time evaluation, because one `todo` I missed was in a
`run_const` function.
This commit is contained in:
Andrej Kolčin
2024-08-24 17:02:02 +03:00
committed by GitHub
parent 525eac1afd
commit 3f332bef35
7 changed files with 76 additions and 65 deletions

View File

@ -2,10 +2,12 @@ use nu_test_support::nu;
#[test]
fn canonical() {
for value in super::random_bytes() {
let outcome = nu!("{} | encode hex | decode hex | to nuon", value);
assert_eq!(outcome.out, value);
}
super::test_canonical("hex");
}
#[test]
fn const_() {
super::test_const("hex");
}
#[test]