1
0
mirror of https://github.com/mxpv/podsync.git synced 2024-05-11 05:55:04 +00:00

Add CodeBuild buildspec and linters

This commit is contained in:
Maksym Pavlenko
2019-01-06 20:45:59 -08:00
parent b11080ffcc
commit 49900d9ab3
3 changed files with 30 additions and 0 deletions

9
.golangci.yml Normal file
View File

@ -0,0 +1,9 @@
linters:
disable-all: true
presets:
- bugs
- unused
- format
- style
- complexity
- performance

17
buildspec.yml Normal file
View File

@ -0,0 +1,17 @@
version: 0.2
env:
parameter-store:
YOUTUBE_TEST_API_KEY: "youtubeKey"
VIMEO_TEST_API_KEY: "vimeoKey"
phases:
install:
commands:
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.12.5
- golangci-lint --version
build:
commands:
- go version
- go test -short ./...
- golangci-lint run

View File

@ -54,6 +54,10 @@ var (
)
func runStorageTests(t *testing.T, createFn func(t *testing.T) storage) {
if testing.Short() {
t.Skip("Skipping storage test in short mode")
}
// Feeds
t.Run("SaveFeed", makeTest(createFn, testSaveFeed))
t.Run("LastAccess", makeTest(createFn, testLastAccess))