Skip to content

Commit

Permalink
Updated unit tests to use MustParseDate
Browse files Browse the repository at this point in the history
  • Loading branch information
twystd committed Jun 6, 2024
1 parent 62eb675 commit d02838d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 3,6 @@ module github.com/uhppoted/uhppote-simulator
go 1.22

require (
github.com/uhppoted/uhppote-core v0.8.9-0.20240605161320-cd6c0e95347b
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240605161930-54dea6fc78b1
github.com/uhppoted/uhppote-core v0.8.9-0.20240606155158-a18316ae7528
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240606160456-0430d2c98f6d
)
4 changes: 4 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 68,8 @@ github.com/uhppoted/uhppote-core v0.8.9-0.20240604153627-4993b61f3ba6 h1:ltffa7T
github.com/uhppoted/uhppote-core v0.8.9-0.20240604153627-4993b61f3ba6/go.mod h1:Q DHtT8s74efLs2b0eF20DRBUL9yBkySwaTQ 0lsEVM=
github.com/uhppoted/uhppote-core v0.8.9-0.20240605161320-cd6c0e95347b h1:8 6eR7uTFE5cD3tdbOjat2NoI/zS3Pj1eK4WXZvQweA=
github.com/uhppoted/uhppote-core v0.8.9-0.20240605161320-cd6c0e95347b/go.mod h1:Q DHtT8s74efLs2b0eF20DRBUL9yBkySwaTQ 0lsEVM=
github.com/uhppoted/uhppote-core v0.8.9-0.20240606155158-a18316ae7528 h1:vNa68NNnTJITeZCfbreLiNT9OCbKQ3EUGByZ6PicEDc=
github.com/uhppoted/uhppote-core v0.8.9-0.20240606155158-a18316ae7528/go.mod h1:Q DHtT8s74efLs2b0eF20DRBUL9yBkySwaTQ 0lsEVM=
github.com/uhppoted/uhppoted-lib v0.8.5 h1:X5RarX5QMRGJvOwPk8ceowrH8k6Ow3t TraWmhYO950=
github.com/uhppoted/uhppoted-lib v0.8.5/go.mod h1:euK2cLO934w0GDgvvnWMjYNtZ29K1xSMrMse6THOzDQ=
github.com/uhppoted/uhppoted-lib v0.8.6-0.20230714155133-57e68f2d1360 h1:XaVqmMmjwskTrX6iCdUl2I4ezrvuoA/yhLzf/455E10=
Expand Down Expand Up @@ -138,3 140,5 @@ github.com/uhppoted/uhppoted-lib v0.8.9-0.20240604154440-5ce365632a38 h1:q42QPpm
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240604154440-5ce365632a38/go.mod h1:MsC5n/1vS80L/S7wcpzpOPeR8UsUNKOMmdOWs/vi5Hg=
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240605161930-54dea6fc78b1 h1:T1tGRfDa/jN9apkZtiid5FmHMMxjNXuazp7Mi9J4K/U=
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240605161930-54dea6fc78b1/go.mod h1:di eHPBWGIN6UwtmjXNPzmKZyoE8VL7f1KDbbw1cFzQ=
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240606160456-0430d2c98f6d h1:tc5XXgrJMMZT8kogXpBJkt4QMO/UYbOIyLVRtxzbp24=
github.com/uhppoted/uhppoted-lib v0.8.9-0.20240606160456-0430d2c98f6d/go.mod h1:9o0r7f2N16ZF4ryNQZOa84e9bByEkP/5YwCwLim0Q3s=
5 changes: 2 additions & 3 deletions simulator/UT0311L04/restore_default_parameters_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 5,6 @@ import (
"net/netip"
"reflect"
"testing"
"time"

"github.com/uhppoted/uhppote-core/messages"
"github.com/uhppoted/uhppote-core/types"
Expand Down Expand Up @@ -53,8 52,8 @@ func TestRestoreDefaultParameters(t *testing.T) {

s.Cards.Put(&entities.Card{
CardNumber: 10058400,
From: types.ToDate(2024, time.January, 1),
To: types.ToDate(2024, time.December, 21),
From: types.MustParseDate("2024-01-01"),
To: types.MustParseDate("2024-12-21"),
Doors: map[uint8]uint8{
1: 1,
2: 1,
Expand Down

0 comments on commit d02838d

Please sign in to comment.