Skip to content

Commit

Permalink
Run colored test on CI
Browse files Browse the repository at this point in the history
  • Loading branch information
mszostok committed Sep 20, 2022
1 parent 0248f2f commit 6bcd2e6
Show file tree
Hide file tree
Showing 12 changed files with 115 additions and 89 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,38 @@ jobs:
timezoneWindows: "Central European Standard Time"
- name: "E2E tests"
uses: magefile/mage-action@5f7a9a23cfef763949ca41834b868167adbd1b59 # v2.0.0
env:
TEST_NAME: '[^TestExamplesColorOutput]'
with:
version: latest
args: test:e2e

colored-e2e-test:
strategy:
matrix:
os: [ macos-latest, ubuntu-latest, windows-latest ]
runs-on: ${{matrix.os}}
steps:
- name: "Set git to use LF"
run: |
git config --global core.autocrlf false
git config --global core.eol lf
- name: "Checkout code"
uses: actions/checkout@v3
- name: "Set up Go"
uses: actions/setup-go@v3
with:
go-version: '1.19.1' # must be hardcoded as it's expected in tests
cache: true
- uses: szenius/set-timezone@a5c1676bd4e141779a42a699cc086f3c5ddd1a6c
with:
timezoneLinux: "Europe/Warsaw"
timezoneMacos: "Europe/Warsaw"
timezoneWindows: "Central European Standard Time"
- name: "Colored E2E tests"
uses: magefile/mage-action@5f7a9a23cfef763949ca41834b868167adbd1b59 # v2.0.0
env:
TEST_NAME: 'TestExamplesColorOutput'
with:
version: latest
args: test:e2e
Expand Down
6 changes: 0 additions & 6 deletions tests/e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ package integration

import (
"fmt"
"os"
"os/exec"
"path/filepath"
"runtime"
Expand Down Expand Up @@ -205,11 +204,6 @@ var cases = []TestCases{
//
// UPDATE_GOLDEN=true TEST_NAME=TestExamplesColorOutput mage test:e2e
func TestExamplesColorOutput(t *testing.T) {
if os.Getenv("CI") == "true" {
t.Skip("Those tests are not stable on CI yet")
}
t.Parallel()

for _, tc := range cases {
tc := tc
t.Run(tc.name, func(t *testing.T) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@

 ╭ ▓▓▓ example ─────────────────────────────────────────────────╮
 │ │
 │ Version 0.6.1 │
 │ Git Commit 324d022 │
 │ Build Date 01 Apr 22 14:22 CEST (5 months ago) │
 │ Commit Date 28 Mar 22 17:32 CEST (5 months ago) │
 │ Dirty Build no │
 │ Go Version 1.19.1 │
 │ Compiler gc │
 │ Platform normalized  │
 │ Version 0.6.1 │
 │ Git Commit 324d022 │
 │ Build Date 01 Apr 22 14:22 CEST (5 months ago) │
 │ Commit Date 28 Mar 22 17:32 CEST (5 months ago) │
 │ Dirty Build no │
 │ Go Version 1.19.1 │
 │ Compiler gc │
 │ Platform normalized  │
 │ │
 ╰──────────────────────────────────────────────────────────────╯
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
│ │
│▓▓▓ example │
│ │
│ Version 0.6.1 │
│ Git Commit 324d022 │
│ Build Date 01 Apr 22 14:22 CEST (5 months ago)│
│ Commit Date 28 Mar 22 17:32 CEST (5 months ago)│
│ Dirty Build no │
│ Go version 1.19.1 │
│ Compiler gc │
│ Platform normalized  │
│ Version 0.6.1 │
│ Git Commit 324d022 │
│ Build Date 01 Apr 22 14:22 CEST (5 months ago)│
│ Commit Date 28 Mar 22 17:32 CEST (5 months ago)│
│ Dirty Build no │
│ Go version 1.19.1 │
│ Compiler gc │
│ Platform normalized  │
│ │
╰────────────────────────────────────────────────────────╯
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Built By GoReleaser
Repository URL https://github.com/mszostok/version
Documentation URL https://szostok.io/projects/version
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Built By GoReleaser
Repository URL https://github.com/mszostok/version
Documentation URL https://szostok.io/projects/version
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
 ╭──────────────────────────────────────────────────────────────────────╮
 │ A new release is available: 0.6.1 → v0.7.4 │
 │ https://github.com/mszostok/codeowners-validator/releases/tag/v0.7.4 │
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized

│ A new release is available: 0.6.1 → v0.7.4
│ https://github.com/mszostok/codeowners-validator/releases/tag/v0.7.4
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

▓▓▓ example

Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized
Version 0.6.1
Git Commit 324d022
Build Date 01 Apr 22 14:22 CEST (5 months ago)
Commit Date 28 Mar 22 17:32 CEST (5 months ago)
Dirty Build no
Go version 1.19.1
Compiler gc
Platform normalized

│ A new release is available: 0.6.1 → v0.7.4
│ https://github.com/mszostok/codeowners-validator/releases/tag/v0.7.4

0 comments on commit 6bcd2e6

Please sign in to comment.