Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
vitelot committed Mar 7, 2023
1 parent 76c892c commit c1c2006
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 116 deletions.
29 changes: 0 additions & 29 deletions tests/data_test/par_test0.ini

This file was deleted.

29 changes: 0 additions & 29 deletions tests/data_test/par_test1.ini

This file was deleted.

29 changes: 0 additions & 29 deletions tests/data_test/par_test2.ini

This file was deleted.

19 changes: 0 additions & 19 deletions tests/data_test/timetable_realtime_test.csv

This file was deleted.

20 changes: 10 additions & 10 deletions tests/simulation_test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ include("../simulation/functions.jl")

#netStatus(S::Set{String}, BK::Dict{String,Block}; hashing::Bool=false)

@testset "functions" begin
# @testset "functions" begin

S=Set{String}(["SB29953"])
BK=Dict{String,Block}("FLDH1-FLDU2" => Block("FLDH1-FLDU2", false, 1, 1, Set{String}(["SB29953"])), "FLDU2-FLDH1" => Block("FLDU2-FLDH1", false, 1, 0, Set{String}()))
# S=Set{String}(["SB29953"])
# BK=Dict{String,Block}("FLDH1-FLDU2" => Block("FLDH1-FLDU2", false, 1, 1, Set{String}(["SB29953"])), "FLDU2-FLDH1" => Block("FLDU2-FLDH1", false, 1, 0, Set{String}()))

schedule=[Transit("SB29541", "WSP", "Ankunft", 200), Transit("SB29541", "WSP", "Abfahrt", 100)]
# hashing=true
# schedule=[Transit("SB29541", "WSP", "Ankunft", 200), Transit("SB29541", "WSP", "Abfahrt", 100)]
# # hashing=true

@test netStatus(S, BK; hashing=true)==0x121c97cea605b461
# @test netStatus(S, BK; hashing=true)==0x121c97cea605b461

@test netStatus(S, BK; hashing=false)=="FLDH1-FLDU2:Set([\"SB29953\"]) "
# @test netStatus(S, BK; hashing=false)=="FLDH1-FLDU2:Set([\"SB29953\"]) "

@test netStatus(Set{String}(), BK)==""
# @test netStatus(Set{String}(), BK)==""

@test sort!(schedule)[1].duetime==100
end
# @test sort!(schedule)[1].duetime==100
# end

0 comments on commit c1c2006

Please sign in to comment.