Skip to content

Commit 63b2eed

Browse files
committed
run tests
Signed-off-by: alanprot <alanprot@gmail.com>
1 parent dd49691 commit 63b2eed

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/test-build-deploy.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,43 @@ jobs:
2828
ln -s $GITHUB_WORKSPACE/* /go/src/github.com/cortexproject/weaveworks-common
2929
- name: Lint
3030
run: make lint
31+
32+
protos:
33+
runs-on: ubuntu-20.04
34+
steps:
35+
- name: Checkout Repo
36+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
37+
- name: Setup Git safe.directory
38+
run: |
39+
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
40+
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
41+
git config --system --add safe.directory $GITHUB_WORKSPACE
42+
# Commands in the Makefile are hardcoded with an assumed file structure of the CI container
43+
# Symlink ensures paths specified in previous commands don’t break
44+
- name: Sym Link Expected Path to Workspace
45+
run: |
46+
mkdir -p /go/src/github.com/cortexproject/weaveworks-common
47+
ln -s $GITHUB_WORKSPACE/* /go/src/github.com/cortexproject/weaveworks-common
48+
- name: CheckProtos
49+
run: make check-protos
50+
51+
test:
52+
runs-on: ubuntu-20.04
53+
container:
54+
image: quay.io/cortexproject/build-image:master-0ddced051
55+
steps:
56+
- name: Checkout Repo
57+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
58+
- name: Setup Git safe.directory
59+
run: |
60+
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
61+
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
62+
git config --system --add safe.directory $GITHUB_WORKSPACE
63+
# Commands in the Makefile are hardcoded with an assumed file structure of the CI container
64+
# Symlink ensures paths specified in previous commands don’t break
65+
- name: Sym Link Expected Path to Workspace
66+
run: |
67+
mkdir -p /go/src/github.com/cortexproject/weaveworks-common
68+
ln -s $GITHUB_WORKSPACE/* /go/src/github.com/cortexproject/weaveworks-common
69+
- name: Test
70+
run: make test

0 commit comments

Comments
 (0)