Skip to content
This repository was archived by the owner on Jun 10, 2024. It is now read-only.

Commit 120a1af

Browse files
committed
Filter lists to exclude arguments and not just arity
1 parent 146fd33 commit 120a1af

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

lumen_runtime/src/otp/erlang/tests/raise_3/with_atom_class.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ fn with_class_with_stacktrace_with_atom_module_with_atom_function_without_arity_
146146
strategy::term(arc_process.clone()),
147147
strategy::term::function::module(),
148148
strategy::term::function::function(),
149-
strategy::term::is_not_non_negative_integer(arc_process.clone()),
149+
is_not_arity_or_arguments(arc_process.clone()),
150150
),
151151
|(class, reason, module, function, arity_or_arguments)| {
152152
let stacktrace = Term::slice_to_list(
@@ -536,3 +536,11 @@ fn class_variant_and_term() -> BoxedStrategy<(Class, Term)> {
536536
})
537537
.boxed()
538538
}
539+
540+
fn is_not_arity_or_arguments(arc_process: Arc<Process>) -> BoxedStrategy<Term> {
541+
strategy::term::is_not_non_negative_integer(arc_process.clone())
542+
.prop_filter("Is not arguments", |arity_or_arguments| {
543+
!arity_or_arguments.is_list()
544+
})
545+
.boxed()
546+
}

0 commit comments

Comments
 (0)