Skip to content

Commit

Permalink
Merge pull request #48 from JuliaIO/an/seed
Browse files Browse the repository at this point in the history
 Use Random.seed! instead of srand
  • Loading branch information
SimonDanisch authored Aug 22, 2018
2 parents bdaafc9 + 49c002a commit 253b489
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 14 deletions.
9 changes: 1 addition & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,12 @@ os:
- osx
julia:
- 0.7
- 1.0
- nightly
matrix:
allow_failures:
- julia: nightly
notifications:
email: false
#script: # use the default script setting which is equivalent to the following
# - if [[ -a .git/shallow ]]; then git fetch --unshallow; fi
# - julia -e 'Pkg.clone(pwd()); Pkg.build("QuartzImageIO");'
# - julia -e 'Pkg.test("QuartzImageIO"; coverage=true)'
script:
- if [[ -a .git/shallow ]]; then git fetch --unshallow; fi
- julia -e 'Pkg.clone(pwd())'
- CGBITMAP_CONTEXT_LOG_ERRORS=1 julia -e 'Pkg.test("QuartzImageIO"; coverage=true)'
after_success:
- julia -e 'cd(Pkg.dir("QuartzImageIO")); Pkg.add("Coverage"); using Coverage; Codecov.submit(process_folder())'
6 changes: 3 additions & 3 deletions REQUIRE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
julia 0.7.0-beta2
FileIO 1.0.0
julia 0.7
FileIO 1.0
ImageCore 0.7
ColorTypes 0.3
ColorVectorSpace 0.2
FixedPointNumbers 0.3.0
FixedPointNumbers 0.3
6 changes: 3 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ end

@testset "HSV" begin
# issue 37
srand(42)
Random.seed!(42)
img = rand(HSV{Float32}, 8, 10)
out_name = joinpath(mydir, "hsv.png")
save(out_name, img)
Expand All @@ -267,7 +267,7 @@ end
end

@testset "HSL" begin
srand(42)
Random.seed!(42)
img = rand(HSL{Float32}, 8, 10)
out_name = joinpath(mydir, "hsl.png")
save(out_name, img)
Expand All @@ -278,7 +278,7 @@ end
end

@testset "Lab" begin
srand(42)
Random.seed!(42)
img = rand(Lab{Float32}, 8, 10)
out_name = joinpath(mydir, "Lab.png")
save(out_name, img)
Expand Down

0 comments on commit 253b489

Please sign in to comment.