Add test case for second part
This commit is contained in:
parent
07b32d8ff8
commit
c529a96f30
|
@ -119,6 +119,12 @@ mod tests {
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
sum_muls("xmul(2,4)%&mul[3,7]!@^do_not_mul(5,5)+mul(32,64]then(mul(11,8)mul(8,5))"),
|
sum_muls("xmul(2,4)%&mul[3,7]!@^do_not_mul(5,5)+mul(32,64]then(mul(11,8)mul(8,5))"),
|
||||||
161
|
161
|
||||||
)
|
);
|
||||||
|
assert_eq!(
|
||||||
|
sum_muls_with_do_and_dont(
|
||||||
|
"xmul(2,4)&mul[3,7]!^don't()_mul(5,5)+mul(32,64](mul(11,8)undo()?mul(8,5))"
|
||||||
|
),
|
||||||
|
48
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue