https://discourse.julialang.org/t/how-to-use-test-skip-properly/2628์ ๋ฐ๋ผ
๋ค์ ์ฝ๋๋ @test_skip
๊ฐ CI ์ฑ๊ณต/์คํจ์ ๊ธฐ์ฌํ์ง ์์๋ CI ์คํจ๋ฅผ ์ ๋ฐํฉ๋๋ค.
using LightGraphs
using LightGraphs.LinAlg
using Base.Test
<strong i="9">@testset</strong> "foo" begin
<strong i="10">@test_skip</strong> 1 == 2
end
์์ต๋ฅ
julia> Pkg.test("LightGraphs")
INFO: Testing LightGraphs
Test Summary: | Broken Total
foo | 1 1
ERROR: LoadError: Some tests did not pass: 0 passed, 0 failed, 0 errored, 1 broken.
CI ์คํจ๋ฅผ ์ ๋ฐํฉ๋๋ค.
์ด๊ฒ์ ๋ถ๋ช ํ 0.6์์ ์์ ๋์์ง๋ง ์์ง ํ์ธํ์ง ๋ชปํ์ต๋๋ค.
Bisect๋ ์ด ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ๊ธฐ ์ํด 8982605c1998์ ์๋ณํฉ๋๋ค. ์ฐ๋ฆฌ๊ฐ ๋ณํฉํ ํด๋น PR ๋ฒ์ ์ด bisect-clean ๋ฒ์ ์ด์ด์ ๊ธฐ์ฉ๋๋ค.
๊ทธ ์ปค๋ฐ์ ๋ฐฑํฌํธํ๊ธฐ์๋ ๋๋ฌด ํฌ๊ณ ๋ฐฉํด๊ฐ ๋์ง๋ง, ์ด ์ปค๋ฐ์ ์์ ๋ถ๋ถ ์งํฉ์ ์ด ๋ฒ๊ทธ๋ฅผ ์์ ํ๊ธฐ์ ์ถฉ๋ถํ ๊ฒ์ ๋๋ค. ํ ์คํธ ์ธํธ์ ์ฑ๊ณต ๋๋ ์คํจ ์ฌ๋ถ๋ฅผ ๊ฒฐ์ ํ๋ ๋ฐ ๊ณ ์ฅ๋ ํ ์คํธ์ ์๋ฅผ ์ธ๋ ๊ฒ์ผ ์ ์์ต๋๋ค.
๋๋ ์ด๊ฒ์ @test_broken
. ๋ค์์ 0.5.2๊น์ง ์ฌ์ฉํ๋ ํด๊ฒฐ ๋ฐฉ๋ฒ์
๋๋ค.
using Base.Test
if VERSION < v"0.6-"
# Override Test.<strong i="7">@test_broken</strong>, which is broken on julia-0.5!
# See https://github.com/JuliaLang/julia/issues/21008
macro test_broken(exs...)
esc(:(<strong i="8">@test</strong> !($(exs...))))
end
end
0.5.2์์ ์์ ๋์์ผ๋ฉฐ ๊ณง ํ๊ทธ๊ฐ ์ง์ ๋๊ณ ์ ๋ก๋๋ฉ๋๋ค.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
0.5.2์์ ์์ ๋์์ผ๋ฉฐ ๊ณง ํ๊ทธ๊ฐ ์ง์ ๋๊ณ ์ ๋ก๋๋ฉ๋๋ค.