Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
8cde2e0e
Unverified
Commit
8cde2e0e
authored
Apr 02, 2017
by
Christoph Blecker
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix coverage report testing on macOS
parent
4fa902a9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
test.sh
hack/make-rules/test.sh
+4
-3
No files found.
hack/make-rules/test.sh
View file @
8cde2e0e
...
@@ -185,8 +185,8 @@ junitFilenamePrefix() {
...
@@ -185,8 +185,8 @@ junitFilenamePrefix() {
# exceeding 255 character filename limit. KUBE_TEST_API
# exceeding 255 character filename limit. KUBE_TEST_API
# barely fits there and in coverage mode test names are
# barely fits there and in coverage mode test names are
# appended to generated file names, easily exceeding
# appended to generated file names, easily exceeding
# 255 chars in length. So let's just
sha1sum
it.
# 255 chars in length. So let's just
use a sha1 hash of
it.
local
KUBE_TEST_API_HASH
=
"
$(
echo
-n
"
${
KUBE_TEST_API
//\//-
}
"
|sha
1sum
|awk
'{print $1}'
)
"
local
KUBE_TEST_API_HASH
=
"
$(
echo
-n
"
${
KUBE_TEST_API
//\//-
}
"
|sha
sum
-a
1
|awk
'{print $1}'
)
"
echo
"
${
KUBE_JUNIT_REPORT_DIR
}
/junit_
${
KUBE_TEST_API_HASH
}
_
$(
kube::util::sortable_date
)
"
echo
"
${
KUBE_JUNIT_REPORT_DIR
}
/junit_
${
KUBE_TEST_API_HASH
}
_
$(
kube::util::sortable_date
)
"
}
}
...
@@ -236,7 +236,8 @@ runTests() {
...
@@ -236,7 +236,8 @@ runTests() {
fi
fi
# Create coverage report directories.
# Create coverage report directories.
cover_report_dir
=
"/tmp/k8s_coverage/
${
KUBE_TEST_API
}
/
$(
kube::util::sortable_date
)
"
KUBE_TEST_API_HASH
=
"
$(
echo
-n
"
${
KUBE_TEST_API
//\//-
}
"
|shasum
-a
1|awk
'{print $1}'
)
"
cover_report_dir
=
"/tmp/k8s_coverage/
${
KUBE_TEST_API_HASH
}
/
$(
kube::util::sortable_date
)
"
cover_profile
=
"coverage.out"
# Name for each individual coverage profile
cover_profile
=
"coverage.out"
# Name for each individual coverage profile
kube::log::status
"Saving coverage output in '
${
cover_report_dir
}
'"
kube::log::status
"Saving coverage output in '
${
cover_report_dir
}
'"
mkdir
-p
"
${
@+
${
@/#/
${
cover_report_dir
}
/
}}
"
mkdir
-p
"
${
@+
${
@/#/
${
cover_report_dir
}
/
}}
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment