Skip to content

Commit

Permalink
Merge pull request #491 from gururajsh/main
Browse files Browse the repository at this point in the history
Add Test workflow to PR
  • Loading branch information
joaopapereira committed Aug 26, 2024
2 parents 9e97aeb + f4b47c6 commit c9a6033
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: "Unit Tests"

on:
workflow_dispatch:
pull_request:
branches:
- main

permissions:
contents: write

Expand All @@ -13,23 +13,22 @@ defaults:

jobs:
test:
name: Running Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v3
with:
go-version-file: go.mod
check-latest: true

- name: Run Tests
run: |
export GOPATH=$HOME/cli-plugin-repo
export PATH=$GOPATH/bin:$PATH
bin/test
env:
BINARY_VALIDATION: false
- name: Checkout Plugin repo
uses: actions/checkout@v4

- name: Set Up Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
check-latest: true

- name: Run Tests
run: |
set -ex
export GOPATH=$PWD/gopath
export PATH=$GOPATH/bin:$PATH
BINARY_VALIDATION=false bin/test

0 comments on commit c9a6033

Please sign in to comment.