-
Notifications
You must be signed in to change notification settings - Fork 531
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added unit tests for format #3606
Conversation
/rebase |
🕗 /rebase is running, please wait for completion. |
🔨 Auto rebase from
|
b5c4a3e
to
34e195a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @ashishajr . We should add another test unit when the format specifier is not valid for instance format "%%%"
. The code is panicking with this input so the new test should be marked with #[should_panic]
.
I'm creating a new bug issue so we'll fix this panic!
and have a good error message.
42a8ee6
to
148d4dd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good thanks @ashishajr !
Thanks for all the help @jcamiel :) |
/rebase |
🕗 /rebase is running, please wait for completion. |
148d4dd
to
9f117d7
Compare
@jcamiel, could you please hold off on accepting this PR, I made a mistake, the newest test is panicking for the wrong reason. It's panicking because I'm calling fn eval_filter_format_ko_invalid_format() {
let variables = VariableSet::new();
let filter = new_format_filter("%%");
eval_filter(
&filter,
&Value::String("01/01/2025".to_string()), // <- Should be Value::Date
&variables,
false,
)
.unwrap(); // <- Test is panicking here
} My apologies, let me quickly fix this |
No worries, good catch! |
Should be fixed now! |
d3cc865
to
ebbd608
Compare
/rebase |
🕗 /rebase is running, please wait for completion. |
🔨 Auto rebase from
|
ebbd608
to
96b80af
Compare
/accept |
🕗 /accept is running, please wait for completion. |
Description
Added unit tests for
hurl::runner::filter::format
Related Issue
Add unit tests on hurl::runner::filter