Skip to content

Commit a560aaf

Browse files
author
Tomasz Wojcikowski
committed
Refactor small suite path function to improve log file retrieval
1 parent bb3b809 commit a560aaf

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

tools/circle-publish-github-comment.sh

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -85,12 +85,10 @@ function last_ct_run_name
8585
}
8686

8787

88-
function small_suite_path
88+
function last_small_ct_run_name
8989
{
9090
if [ -d _build/test/logs ]; then
91-
cd _build/test/logs
92-
ls -t -1 ct_run.mongooseim@localhost.*/lib.mongooseim.logs/run.*/suite.log.html
93-
cd ../../..
91+
ls -1 -t _build/test/logs/ | grep ct_run | head -n1
9492
fi
9593
}
9694

@@ -106,8 +104,8 @@ function ct_small_url
106104
{
107105
local CT_REPORTS=$(ct_reports_dir)
108106
local SMALL_TESTS_URL="$(archive_reader_url small ${CT_REPORTS})"
109-
local SUFFIX=$(small_suite_path)
110-
echo "$SMALL_TESTS_URL/$SUFFIX"
107+
local RUN_PART=$(echo "$(last_small_ct_run_name)" | sed "s/@/%40/g")
108+
echo "$SMALL_TESTS_URL/$RUN_PART/index.html"
111109
}
112110

113111
function reports_url

0 commit comments

Comments
 (0)