Gitly
English
Русский
Español
日本語
中文
Português
Log in
Register
v2
/
vlib
/
v
/
tests
/
assign
/
assert_fn_call_with_parentheses_test.v
7
lines
·
6
sloc
·
169 bytes
·
6488041a749df9762348d019c4223908c476f2e2
Raw
1
fn
foo(fail bool) ?string {
2
return
if
fail { error(
'failure'
) }
else
{
'success'
}
3
}
4
5
fn
test_assert_fn_call_with_parentheses() {
6
assert (foo(
true
)
or
{
''
}) ==
''
7
}
8