Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct log files for Qconnect #440

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions scripts/Bash/collect_log.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,8 @@ for target_dir in "${value_array[@]}"; do
cp -rf $source_log_file/* $destination_log_file
if [ $? -ne 0 ]; then
real_src_path=$(realpath $(dirname $source_log_file))
echo -e "\e[31mError:\e[0m No files to copy files from $real_src_path"
echo "Please correct the directory to contain all log files."
exit 1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The wording is a bit curious. Files are missing. This is interpreted as error. OK so far. But do we really need an additional hint that something needs to be corrected? I don't think so.

How about a shorter version:

Error: No log files found in '$real_src_path'.

This should be enough.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Holger,

I think we need to warn the user to pay attention to additional test log files.
Therefore, I will change "Error" to "Warning" with a shorter version, as you mentioned.

Please help me review it and let me know if you have any concerns.

Best regards,
Thong Hua

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Thong,

fine to me.

Best regards

Holger

echo -e "\e[33mWarning:\e[0m No additional test log files found in $real_src_path"
fi
done

echo "All test logfiles have been successfully collected"
echo "All the existing test log files have been successfully collected."
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,7 @@
"TESTFOLDER" : "test",
"TESTTYPE" : "ROBOT",
"TESTEXECUTOR" : "executerobottest.py",
"LOGFILE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles/aiotestlogfile.xml",
"FILES_SAVE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles"
"LOGFILE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles/aiotestlogfile.xml"
},
{
"COMPONENTROOTPATH" : "../../../../robotframework",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,7 @@
"TESTTYPE" : "ROBOT",
"TESTEXECUTOR" : "executerobottest.py",
"LOCALCOMMANDLINE" : ["--exclude threading"],
"LOGFILE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles/aiotestlogfile.xml",
"FILES_SAVE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles"
"LOGFILE" : "../../../../robotframework-qconnect-base/test/aiotestlogfiles/aiotestlogfile.xml"
}
],

Expand Down