@@ -58,7 +58,12 @@ my_stable_add_undecorated(y) = my_add(y)
58
58
@test warns_for (ws, " returns" )
59
59
60
60
ws = Traceur. warnings (() -> naive_sum ([1 ]))
61
- @test isempty (ws)
61
+ if Base. VERSION >= v " 1.2.0"
62
+ @test length (ws) == 4
63
+ @test warns_for (ws, " assigned" )
64
+ else
65
+ @test isempty (ws)
66
+ end
62
67
63
68
ws = Traceur. warnings (() -> naive_sum ([1.0 ]))
64
69
@test warns_for (ws, " assigned" , " returns" )
@@ -78,7 +83,11 @@ my_stable_add_undecorated(y) = my_add(y)
78
83
@test warns_for (ws, " returns" )
79
84
80
85
ws = Traceur. warnings (() -> naive_sum_wrapper (rand (3 )); maxdepth = 1 )
81
- @test length (ws) == 4
86
+ if Base. VERSION >= v " 1.2.0"
87
+ @test length (ws) == 6
88
+ else
89
+ @test length (ws) == 4
90
+ end
82
91
@test warns_for (ws, " assigned" , " returns" )
83
92
end
84
93
@@ -88,11 +97,19 @@ my_stable_add_undecorated(y) = my_add(y)
88
97
@test warns_for (ws, " returns" )
89
98
90
99
ws = Traceur. warnings (() -> Foo. naive_sum_wrapper (rand (3 )); maxdepth = 2 , modules= [Foo. Bar])
91
- @test length (ws) == 3
100
+ if Base. VERSION >= v " 1.2.0"
101
+ @test length (ws) == 5
102
+ else
103
+ @test length (ws) == 3
104
+ end
92
105
@test warns_for (ws, " assigned" , " returns" )
93
106
94
107
ws = Traceur. warnings (() -> Foo. naive_sum_wrapper (rand (3 )); maxdepth = 2 , modules= [Foo, Foo. Bar])
95
- @test length (ws) == 4
108
+ if Base. VERSION >= v " 1.2.0"
109
+ @test length (ws) == 6
110
+ else
111
+ @test length (ws) == 4
112
+ end
96
113
@test warns_for (ws, " assigned" , " returns" )
97
114
end
98
115
0 commit comments