Skip to content

Commit a16aefd

Browse files
committed
fix error for docker unit test
1 parent af167c8 commit a16aefd

2 files changed

Lines changed: 13 additions & 3 deletions

File tree

.github/workflows/build.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ on:
2929
default: false
3030
type: boolean
3131
Release:
32-
description: 'Release check'
32+
description: 'Check release'
3333
default: false
3434
type: boolean
3535
Binary:
@@ -75,9 +75,10 @@ jobs:
7575
echo "- **OS**: ${{ github.event.inputs.Distro }}" >> $GITHUB_STEP_SUMMARY
7676
echo "- **Version**: $version" >> $GITHUB_STEP_SUMMARY
7777
echo "- **Update dependencies**: ${{ github.event.inputs.Update }}" >> $GITHUB_STEP_SUMMARY
78-
echo "- **Linter check**: ${{ github.event.inputs.Linter }}" >> $GITHUB_STEP_SUMMARY
78+
echo "- **Check linters**: ${{ github.event.inputs.Linter }}" >> $GITHUB_STEP_SUMMARY
79+
echo "- **Check all linters**: ${{ github.event.inputs.LinterAll }}" >> $GITHUB_STEP_SUMMARY
7980
echo "- **Unit testing**: ${{ github.event.inputs.Test }}" >> $GITHUB_STEP_SUMMARY
80-
echo "- **Release check**: ${{ github.event.inputs.Release }}" >> $GITHUB_STEP_SUMMARY
81+
echo "- **Check release**: ${{ github.event.inputs.Release }}" >> $GITHUB_STEP_SUMMARY
8182
echo "- **Build binary**: ${{ github.event.inputs.Binary }}" >> $GITHUB_STEP_SUMMARY
8283
echo "- **Build docker image**: ${{ github.event.inputs.Docker }}" >> $GITHUB_STEP_SUMMARY
8384
shell: bash

main_test.go

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,15 @@ func TestDockerContainer(t *testing.T) {
357357
syslogUnitRegex: syslogUnitRegex,
358358
}
359359

360+
app.uniquePrefixColorMap = make(map[string]string)
361+
app.uniquePrefixColorArr = append(app.uniquePrefixColorArr,
362+
"\033[32m",
363+
"\033[33m",
364+
"\033[34m",
365+
"\033[35m",
366+
"\033[36m",
367+
)
368+
360369
app.loadDockerContainer(app.selectContainerizationSystem)
361370
if len(app.dockerContainers) == 0 {
362371
t.Errorf("Container list is null")

0 commit comments

Comments
 (0)