Skip to content

Commit

Permalink
Fix tests + run only tests on pull requests
Browse files Browse the repository at this point in the history
  • Loading branch information
Dbzman committed May 25, 2020
1 parent 1f8761b commit 13f919c
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/go.yml → .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Test and build Docker image

on: [push, pull_request]
on:
push:
branches:
- master

jobs:
build:
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Run tests

on: [pull_request]

jobs:
build:
name: Run tests
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.14
uses: actions/setup-go@v1
with:
go-version: 1.14
id: go
- name: Check out code
uses: actions/checkout@v2
- name: Test
run: go test -v ./...
2 changes: 1 addition & 1 deletion server.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func handler(crucibleSettings CrucibleSettings, gitLabSettings GitLabSettings, c
return
}

err = TriggerCrucibleSync(projectId, client, crucibleSettings)
err = TriggerCrucibleSync(projectId, client, &crucibleSettings)
if err != nil {
log.Printf("error when sending request to Crucible: %s\n", err.Error())
http.Error(w, err.Error(), http.StatusInternalServerError)
Expand Down

0 comments on commit 13f919c

Please sign in to comment.