Skip to content

Commit

Permalink
Tests for bad arguments to at-threads (#30937)
Browse files Browse the repository at this point in the history
  • Loading branch information
kshyatt authored and pull[bot] committed Jun 9, 2022
1 parent 28b4286 commit a117008
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/threads.jl
Original file line number Diff line number Diff line change
Expand Up @@ -304,3 +304,9 @@ close(proc.in)
end
end
end

@testset "bad arguments to @threads" begin
@test_throws ArgumentError @macroexpand(@threads 1 2) # wrong number of args
@test_throws ArgumentError @macroexpand(@threads 1) # arg isn't an Expr
@test_throws ArgumentError @macroexpand(@threads if true 1 end) # arg doesn't start with for
end

0 comments on commit a117008

Please sign in to comment.