Skip to content

Commit

Permalink
more test
Browse files Browse the repository at this point in the history
  • Loading branch information
Kyjor committed Sep 26, 2024
1 parent cbccb97 commit 9160318
Showing 3 changed files with 17 additions and 13 deletions.
1 change: 1 addition & 0 deletions test/math/mathtests.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
using JulGame
@testset "Math tests" begin
include("lerptests.jl")
include("vectortests.jl")
3 changes: 3 additions & 0 deletions test/projects/ProfilingTest/Platformer/src/Platformer.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
module PlatformerModule
using JulGame
function run_platformer()
JulGame.MAIN = JulGame.Main(Float64(1.0))
MAIN.testMode = true
@@ -15,6 +17,7 @@

return 0
end
end # module

# comment when building
# Platformer.run()
26 changes: 13 additions & 13 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -5,24 +5,24 @@ EXAMPLEGAMEDIR = joinpath(ROOTDIR, "examples")
SMOKETESTDIR = joinpath(@__DIR__, "projects", "SmokeTest")
PROFILINGTESTDIR = joinpath(@__DIR__, "projects", "ProfilingTest")
include(joinpath(SMOKETESTDIR, "src", "SmokeTest.jl"))
# include(joinpath(PROFILINGTESTDIR, "Platformer", "src", "Platformer.jl"))
include(joinpath(PROFILINGTESTDIR, "Platformer", "src", "Platformer.jl"))

@testset "All tests" begin
# cd(joinpath(@__DIR__, "projects", "ProfilingTest", "Platformer", "src"))
# @testset "Platformer" begin
# @test run_platformer() == 0
# end
cd(joinpath(@__DIR__, "projects", "ProfilingTest", "Platformer", "src"))
@testset "Platformer" begin
@test PlatformerModule.run_platformer() == 0
end

#include("math/mathtests.jl")
include("math/mathtests.jl")

cd(joinpath(SMOKETESTDIR, "src"))
@test SmokeTest.run(SMOKETESTDIR, Test) == 0

# if !Sys.islinux()
# cd(joinpath(ROOTDIR, "src", "editor", "JulGameEditor", "src"))
# include(joinpath(ROOTDIR, "src", "editor", "JulGameEditor", "src", "../Editor.jl"))
# @testset "Editor" begin
# @test Editor.run(true) == 0
# end
# end
if !Sys.islinux()
cd(joinpath(ROOTDIR, "src", "editor", "JulGameEditor", "src"))
include(joinpath(ROOTDIR, "src", "editor", "JulGameEditor", "src", "../Editor.jl"))
@testset "Editor" begin
@test Editor.run(true) == 0
end
end
end

0 comments on commit 9160318

Please sign in to comment.