include all groups in runtests.jl

This commit is contained in:
kalmarek 2018-09-05 17:57:25 +02:00
parent 385d2d4f5e
commit a1e4a917a6

View File

@ -3,79 +3,156 @@ using Base.Test
include("main.jl") include("main.jl")
testdir = "tests_"*string(now()) testdir = "tests_"*string(now())
info(testdir)
mkdir(testdir) mkdir(testdir)
include("logging.jl")
logger=setup_logging(joinpath(testdir, "tests.log"))
info(testdir)
cd(testdir) cd(testdir)
# groupname = name(G)
# ub = PARSEDARGS["upper-bound"]
#
# fullpath = joinpath(groupname, string(ub))
# isdir(fullpath) || mkpath(fullpath)
separator(n=60) = info("\n"*("\n"*"="^n*"\n"^3)*"\n")
function SL_tests(args) function SL_tests(args)
G = PropertyTGroups.SpecialLinearGroup(args)
args["SL"] = 2
args["p"] = 3 args["p"] = 3
G = PropertyTGroup(args)
@test main(G) == true @test main(G) == true
separator()
println("\n"*"="^30*"\n") let args = args
args["SL"] = 2
begin
args["p"] = 5 args["p"] = 5
G = PropertyTGroups.SpecialLinearGroup(args) G = PropertyTGroup(args)
@test main(G) == false @test main(G) == false
separator()
args["warmstart"] = true args["warmstart"] = true
G = PropertyTGroups.SpecialLinearGroup(args) G = PropertyTGroup(args)
@test main(G) == false @test main(G) == false
separator()
args["upper-bound"] = 0.1
G = PropertyTGroup(args)
@test main(G) == true
separator()
end end
println("\n"*"="^30*"\n") args["SL"] = 2
begin
args["p"] = 7 args["p"] = 7
G = PropertyTGroups.SpecialLinearGroup(args) G = PropertyTGroup(args)
@test main(G) == false @test main(G) == false
separator()
println("\n"*"="^30*"\n") args["SL"] = 3
args["p"] = 7
args["upper-bound"] = 0.25 G = PropertyTGroup(args)
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == false
end
println("\n"*"="^30*"\n")
args["N"] = 3
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == true @test main(G) == true
separator()
println("\n"*"="^30*"\n") # begin
# args["iterations"] = 25000
# args["N"] = 3
# args["p"] = 0
# args["upper-bound"] = Inf
#
# G = PropertyTGroups.SpecialLinearGroup(args)
# @test main(G) == false
# separator()
#
# args["warmstart"] = false
# args["upper-bound"] = 0.27
# G = PropertyTGroups.SpecialLinearGroup(args)
# @test main(G) == false
# separator()
#
# args["warmstart"] = true
# G = PropertyTGroups.SpecialLinearGroup(args)
# @test main(G) == true
# separator()
# end
begin return 0
args["p"] = 0
args["iterations"] = 50000
args["upper-bound"] = Inf
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == false
args["upper-bound"] = 0.27
args["warmstart"] = true
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == false
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == true
G = PropertyTGroups.SpecialLinearGroup(args)
@test main(G) == true
end
return main(G)
end end
@testset "SLn's" begin function SAut_tests(args)
G = PropertyTGroup(args)
@test main(G) == false
separator()
args["warmstart"] = true
G = PropertyTGroup(args)
@test main(G) == false
separator()
args["upper-bound"] = 0.1
G = PropertyTGroup(args)
@test main(G) == false
separator()
return 0
end
@testset "Groups with(out) (T)" begin
@testset "GAPGroups" begin
args = Dict(
"Higman" => true,
"iterations"=>5000,
"tol"=>1e-7,
"upper-bound"=>Inf,
"cpus"=>2,
"radius"=>2,
"warmstart"=>false,
"nosymmetry"=>true,
)
G = PropertyTGroup(args)
@test main(G) == false
args = Dict(
"Caprace" => true,
"iterations"=>5000,
"tol"=>1e-7,
"upper-bound"=>Inf,
"cpus"=>2,
"radius"=>2,
"warmstart"=>false,
"nosymmetry"=>true,
)
G = PropertyTGroup(args)
@test main(G) == false
args = Dict(
"MCG" => 3,
"iterations"=>5000,
"tol"=>1e-7,
"upper-bound"=>Inf,
"cpus"=>2,
"radius"=>2,
"warmstart"=>false,
"nosymmetry"=>true,
)
G = PropertyTGroup(args)
@test main(G) == false
end
@testset "SLn's" begin
@testset "Non-Symmetrized" begin @testset "Non-Symmetrized" begin
args = Dict( args = Dict(
"N" => 2, "SL" => 2,
"p" => 3, "p" => 3,
"X" => false, "X" => false,
"iterations"=>50000, "iterations"=>50000,
@ -93,10 +170,10 @@ end
@testset "Symmetrized" begin @testset "Symmetrized" begin
args = Dict( args = Dict(
"N" => 2, "SL" => 2,
"p" => 3, "p" => 3,
"X" => false, "X" => false,
"iterations"=>50000, "iterations"=>20000,
"tol"=>1e-7, "tol"=>1e-7,
"upper-bound"=>Inf, "upper-bound"=>Inf,
"cpus"=>2, "cpus"=>2,
@ -107,4 +184,39 @@ end
SL_tests(args) SL_tests(args)
end end
end
@testset "SAutF_n's" begin
@testset "Non-Symmetrized" begin
args = Dict(
"SAut" => 2,
"iterations"=>5000,
"tol"=>1e-7,
"upper-bound"=>Inf,
"cpus"=>2,
"radius"=>2,
"warmstart"=>false,
"nosymmetry"=>true,
)
SAut_tests(args)
end
@testset "Symmetrized" begin
args = Dict(
"SAut" => 3,
"iterations"=>500,
"tol"=>1e-7,
"upper-bound"=>Inf,
"cpus"=>2,
"radius"=>2,
"warmstart"=>false,
"nosymmetry"=>false,
)
SAut_tests(args)
end
end
end end