Commit Graph

23 Commits

Author SHA1 Message Date
ThinkChaos 8c7b89cbb3 refactor(tests): remove `TmpFile.Error` to centralize error checks 2023-12-01 15:53:11 -05:00
Kwitsch 3378316982
Refactoring: FileDownloader (#1281)
* enabled containedctx & contextcheck

* enabled noctx

* less background context

* context metrics test

* use ginkgo context instead of background

* fix redis e2e tests

* made downloader context aware
2023-11-29 18:18:29 +01:00
Kwitsch fda2dbe9df
Refactoring Redis (#1271)
* RedisConfig -> Redis

* moved redis config to seperate file

* bugfix in config test during parallel processing

* implement config.Configurable in Redis config

* use Context in GetRedisCache

* use Context in New

* caching resolver test fix

* use Context in PublishEnabled

* use Context in getResponse

* remove ctx field

* bugfix in api interface test

* propperly close channels

* set ruler for go files from 80 to 111

* line break because function length is to long

* only execute redis.New if it is enabled in config

* stabilized flaky tests

* Update config/redis.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* Update config/redis_test.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* Update config/redis_test.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* Update config/redis_test.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* Update config/redis.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* Update config/redis_test.go

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>

* fix ruler

* redis test refactoring

* vscode setting cleanup

* removed else if chain

* Update redis_test.go

* context race fix

* test fail on missing seintinel servers

* cleanup context usage

* cleanup2

* context fixes

* added context util

* disabled nil context rule for tests

* copy paste error ctxSend -> CtxSend

* use util.CtxSend

* fixed comment

* fixed flaky test

* failsafe and tests

---------

Co-authored-by: ThinkChaos <ThinkChaos@users.noreply.github.com>
2023-11-27 12:08:31 -05:00
Nahshon Unna Tsameret 15bd383460
ginkgolinter: enable all checks and fix findings (#1274)
ginkgolinter configuration argument names may be a bit misleading.
Assuming the linter added to use it, this PR remove all the
supress-warning configurations.

Two error checks now found by the linter and fixed as well.
2023-11-26 16:10:38 +01:00
ThinkChaos 23359d1471 style(config): add `config/migration` to `dot-import` allow-list 2023-11-23 08:45:18 -05:00
ThinkChaos d52c598546
fix(tests): properly silence log output (#1259)
* fix(tests): properly silence log output

Using `init` allows it to also work for benchmarks.
And `log.Silence` was sometimes getting overridden by `log.init`.

* squash: fix(server): don't setup the logger again
2023-11-19 17:51:49 -05:00
Kwitsch 6c000090b1
Unit test refactoring & devcontainer enhancement(#1245)
* Whietlist dot imports for test packages

* improved generate-lcov script

* moved mock_call_sequence to helpertest

* removed default config for markdown

* generate seperate lcov.info for each directory

* path fix in lcov generation script

* ginkgo -> v2.13.1

* fixed redundant strings

* added exampleComKey

* added folder name to finish message

* hide lcov.info in devcontainer

* coverage plugin is bugged if lcov file is excluded

* moved all lcov files to coverage folder

* added requested toos #1251
2023-11-15 16:42:53 +01:00
Kwitsch 7615584944
Feature/ginkgolinter (#1235)
* add ginkgolinter to golangci config

* fixed ginkgolinter errors
2023-11-12 13:40:55 -05:00
Dimitri Herzog 7645ed35a3
chore(build): update golangci-lint to 1.54.2 (#1121) 2023-08-31 14:47:30 +02:00
ThinkChaos cfc3699ab5 feat: support multiple hosts files 2023-07-07 09:16:20 -04:00
Dimitri Herzog c4fb0d7540
chore: update testcontainers version (#821) 2023-01-05 10:30:53 +01:00
Dimitri Herzog f78a57a94d
chore(build): add additional linters (#774)
* chore(build): add nolintlint linter

* chore(build): add usestdlibvars linter
2022-11-29 21:58:26 +01:00
Dimitri Herzog 797d71d57c
chore(build): disable deprecated linters (#767) 2022-11-26 22:11:15 +01:00
Dimitri Herzog fb0810f18d
build(tests): e2e integration tests with docker and testcontainers (#753) 2022-11-24 21:54:52 +01:00
ThinkChaos f724bda5cd Enable nosprintfhostport linter 2022-11-04 08:29:16 +01:00
Dimitri Herzog c10b8fcb80 update: github.com/golangci/golangci-lint and github.com/swaggo/swag 2022-09-03 23:10:59 +02:00
Dimitri Herzog 421807fc22
chore: update golangci-lint (#631) 2022-08-19 22:04:35 +02:00
Dimitri Herzog a4b89537db
update golangci-lint (#510)
* update golangci-lint

* enable gomnd linter

* enable asciicheck linter

* enable bidichk linter

* enable durationcheck linter

* enable errchkjson linter

* enable errorlint linter

* enable exhaustive linter

* enable gomoddirectives linter

* enable gomodguard guard

* enable grouper linter

* enable grouper and ifshort linters

* enable importas linter

* enable makezero linter

* enable nestif linter

* enable nilerr linter

* enable nilnil linter

* enable nlreturn linter

* enable nolintlint linter

* enable predeclared linter

* enable sqlclosecheck linter

* enable tenv linter

* enable wastedassign linter
2022-05-10 09:09:50 +02:00
Dimitri Herzog e59977cfc2 removed deprecated linters 2021-09-18 22:51:20 +02:00
Dimitri Herzog c59c52dc24 removed deprecated linters 2021-04-30 22:45:38 +02:00
Dimitri Herzog b386b5ef1e update golangci-lint, fixint lint errors 2021-03-05 22:59:09 +01:00
Dimitri Herzog eaa4e30db4 update golangci-lint, fixint lint errors 2021-03-05 22:52:22 +01:00
Dimitri Herzog 01a8a402dc initial commit 2020-01-12 18:23:35 +01:00