Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Playground.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@ export add_one

include("add_one.jl")

export substract_three

include("substract_three.jl")

end
3 changes: 3 additions & 0 deletions src/substract_three.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
function substract_three(x)
return x - 3
end
6 changes: 6 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,10 @@ using Playground
@test add_one(1) == 2
@test add_one(0) == 1
@test add_one(-1) == 0
end

@testset "substract_three" begin
@test substract_three(1) == -2
@test substract_three(10) == 7
@test substract_three(3) == 0
end