Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Begining unit test for gorm code #322

Merged
merged 2 commits into from
Nov 3, 2022
Merged
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 .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,7 @@ notes.txt

# Tests
coverage.out

# Go Workspace
go.work
go.work.sum
41 changes: 22 additions & 19 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ require (
github.com/jmpsec/osctrl/utils v0.3.1
github.com/jmpsec/osctrl/version v0.3.1
github.com/olekukonko/tablewriter v0.0.5
github.com/spf13/viper v1.10.1
github.com/urfave/cli/v2 v2.3.0
gorm.io/gorm v1.23.3
github.com/spf13/viper v1.13.0
github.com/urfave/cli/v2 v2.23.0
gorm.io/gorm v1.24.1-0.20221019064659-5dd2bb482755
)

require (
Expand All @@ -89,48 +89,51 @@ require (
github.com/aws/smithy-go v1.12.1 // indirect
github.com/beevik/etree v1.1.0 // indirect
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.1 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
github.com/crewjam/httperr v0.2.0 // indirect
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
github.com/fsnotify/fsnotify v1.5.1 // indirect
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/go-redis/redis/v8 v8.11.4 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/gorilla/securecookie v1.1.1 // indirect
github.com/gorilla/sessions v1.2.1 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/jackc/chunkreader/v2 v2.0.1 // indirect
github.com/jackc/pgconn v1.10.1 // indirect
github.com/jackc/pgconn v1.13.0 // indirect
github.com/jackc/pgio v1.0.0 // indirect
github.com/jackc/pgpassfile v1.0.0 // indirect
github.com/jackc/pgproto3/v2 v2.2.0 // indirect
github.com/jackc/pgproto3/v2 v2.3.1 // indirect
github.com/jackc/pgservicefile v0.0.0-20200714003250-2b9c44734f2b // indirect
github.com/jackc/pgtype v1.9.1 // indirect
github.com/jackc/pgx/v4 v4.14.1 // indirect
github.com/jackc/pgtype v1.12.0 // indirect
github.com/jackc/pgx/v4 v4.17.2 // indirect
github.com/jinzhu/inflection v1.0.0 // indirect
github.com/jinzhu/now v1.1.4 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/jonboulle/clockwork v0.2.2 // indirect
github.com/magiconair/properties v1.8.5 // indirect
github.com/magiconair/properties v1.8.6 // indirect
github.com/mattermost/xml-roundtrip-validator v0.1.0 // indirect
github.com/mattn/go-runewidth v0.0.13 // indirect
github.com/mitchellh/mapstructure v1.4.3 // indirect
github.com/pelletier/go-toml v1.9.4 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pelletier/go-toml/v2 v2.0.5 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/rivo/uniseg v0.2.0 // indirect
github.com/rs/zerolog v1.26.1 // indirect
github.com/russellhaering/goxmldsig v1.1.1 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/segmentio/ksuid v1.0.4 // indirect
github.com/spf13/afero v1.8.0 // indirect
github.com/spf13/cast v1.4.1 // indirect
github.com/spf13/afero v1.8.2 // indirect
github.com/spf13/cast v1.5.0 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/subosito/gotenv v1.2.0 // indirect
golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce // indirect
golang.org/x/sys v0.0.0-20220114195835-da31bd327af9 // indirect
github.com/subosito/gotenv v1.4.1 // indirect
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect
golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa // indirect
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect
golang.org/x/text v0.3.7 // indirect
gopkg.in/ini.v1 v1.66.3 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gorm.io/driver/postgres v1.3.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
gorm.io/driver/postgres v1.4.5 // indirect
)
168 changes: 138 additions & 30 deletions go.sum

Large diffs are not rendered by default.

39 changes: 35 additions & 4 deletions users/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,47 @@ replace github.com/jmpsec/osctrl/queries => ../queries

replace github.com/jmpsec/osctrl/types => ../types

replace github.com/jmpsec/osctrl/environments => ../environments

replace github.com/jmpsec/osctrl/users => ../users

replace github.com/jmpsec/osctrl/utils => ../utils

replace github.com/jmpsec/osctrl/settings => ../settings

replace github.com/jmpsec/osctrl/version => ../version

require (
github.com/DATA-DOG/go-sqlmock v1.5.0
github.com/golang-jwt/jwt/v4 v4.2.0
github.com/jinzhu/gorm v1.9.16
github.com/jmpsec/osctrl/environments v0.0.0-00010101000000-000000000000
github.com/jmpsec/osctrl/types v0.0.0-20220120232002-31ecf3b9f264
golang.org/x/crypto v0.0.0-20220112180741-5e0467b6c7ce
github.com/jmpsec/osctrl/utils v0.0.0-00010101000000-000000000000
github.com/stretchr/testify v1.8.1
golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa
gorm.io/gorm v1.24.1-0.20221019064659-5dd2bb482755
)

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/jackc/chunkreader/v2 v2.0.1 // indirect
github.com/jackc/pgconn v1.13.0 // indirect
github.com/jackc/pgio v1.0.0 // indirect
github.com/jackc/pgpassfile v1.0.0 // indirect
github.com/jackc/pgproto3/v2 v2.3.1 // indirect
github.com/jackc/pgservicefile v0.0.0-20200714003250-2b9c44734f2b // indirect
github.com/jackc/pgtype v1.12.0 // indirect
github.com/jackc/pgx/v4 v4.17.2 // indirect
github.com/jinzhu/inflection v1.0.0 // indirect
github.com/jmpsec/osctrl/nodes v0.0.0-20220120232002-31ecf3b9f264 // indirect
github.com/jinzhu/now v1.1.4 // indirect
github.com/jmpsec/osctrl/nodes v0.3.1 // indirect
github.com/jmpsec/osctrl/queries v0.3.1 // indirect
github.com/lib/pq v1.10.4 // indirect
github.com/jmpsec/osctrl/settings v0.3.1 // indirect
github.com/jmpsec/osctrl/version v0.3.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/segmentio/ksuid v1.0.4 // indirect
golang.org/x/text v0.3.7 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
gorm.io/driver/postgres v1.4.5 // indirect
)
Loading