diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index c34d9f2..33d2822 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -1,5 +1,5 @@ -name: Bug Report -description: "Create a report to help us improve." +name: 🐞 Bug Report +description: Create a report to help us improve. body: - type: checkboxes id: terms diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 00fe7cd..c8ad15f 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,6 +1,6 @@ blank_issues_enabled: false contact_links: - - name: Questions + - name: ❓ Questions url: https://github.com/kvtools/valkeyrie/discussions about: If you have a question, or are looking for advice, please post on our Discussions forum! diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 50be34b..08d13fb 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -1,4 +1,4 @@ -name: Feature request +name: 💡 Feature request description: "Suggest an idea for this project." body: diff --git a/.github/ISSUE_TEMPLATE/new_store.yml b/.github/ISSUE_TEMPLATE/new_store.yml index 6f574b4..9ec5e74 100644 --- a/.github/ISSUE_TEMPLATE/new_store.yml +++ b/.github/ISSUE_TEMPLATE/new_store.yml @@ -1,4 +1,4 @@ -name: Add a new type of store +name: 🧩 Add a new type of store description: "Proposal" body: diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b3d19b9..cd05fc8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,33 +3,21 @@ name: Build and test on: [push, pull_request] env: - GOLANGCI_LINT_VERSION: v1.54.1 + GOLANGCI_LINT_VERSION: v1.59.1 jobs: build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest strategy: matrix: go-version: [stable, oldstable] steps: - - name: Set up Go ${{ matrix.go-version }} - uses: actions/setup-go@v3 + - uses: actions/checkout@v4 + - uses: actions/setup-go@v5 with: go-version: ${{ matrix.go-version }} - - name: Check out code - uses: actions/checkout@v3 - - - name: Cache Go modules - uses: actions/cache@v3 - with: - path: | - ~/pkg/mod - ~/.cache/go-build - key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum') }} - restore-keys: ${{ runner.os }}-${{ matrix.go-version }}-go- - - name: Download and check dependencies run: | go mod tidy diff --git a/.golangci.yml b/.golangci.yml index cef52f3..437fce8 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,7 +1,5 @@ run: timeout: 5m - skip-files: [ ] - skip-dirs: [ ] linters-settings: govet: @@ -78,7 +76,7 @@ linters: - gocyclo - godot - godox - - goerr113 + - err113 - gofmt - gofumpt - goheader @@ -116,7 +114,7 @@ linters: issues: exclude-use-default: false - max-per-linter: 0 + max-issues-per-linter: 0 max-same-issues: 0 exclude: [ ] exclude-rules: diff --git a/go.mod b/go.mod index 7f8ed46..e520cce 100644 --- a/go.mod +++ b/go.mod @@ -2,7 +2,7 @@ module github.com/kvtools/valkeyrie go 1.19 -require github.com/stretchr/testify v1.8.4 +require github.com/stretchr/testify v1.9.0 require ( github.com/davecgh/go-spew v1.1.1 // indirect diff --git a/go.sum b/go.sum index 3d1d8bf..5fe56fd 100644 --- a/go.sum +++ b/go.sum @@ -10,8 +10,8 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/mock_test.go b/mock_test.go index 0747969..d7c3722 100644 --- a/mock_test.go +++ b/mock_test.go @@ -10,7 +10,7 @@ const testStoreName = "mock" func newStore(ctx context.Context, endpoints []string, options Config) (store.Store, error) { cfg, ok := options.(*Config) - if !ok && cfg != nil { + if !ok && options != nil { return nil, &store.InvalidConfigurationError{Store: testStoreName, Config: options} }