Skip to content

Commit

Permalink
tests. Collect full node journal
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidePrincipi committed Nov 27, 2023
1 parent 504f873 commit 22e07b6
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions tests/__init__.robot
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
*** Settings ***
Library SSHLibrary
Library DateTime
Suite Setup Setup connection and test suite tools
Suite Teardown Tear down connection and test suite tools

*** Variables ***
${SSH_KEYFILE} %{HOME}/.ssh/id_ecdsa
${NODE_ADDR} 127.0.0.1

*** Keywords ***
Connect to the node
Expand All @@ -11,5 +15,17 @@ Connect to the node
${output} = Execute Command systemctl is-system-running --wait
Should Be True '${output}' == 'running' or '${output}' == 'degraded'

*** Settings ***
Suite Setup Connect to the Node
Setup connection and test suite tools
Connect to the node
Save the journal begin timestamp

Tear down connection and test suite tools
Collect the suite journal

Save the journal begin timestamp
${tsnow} = Get Current Date result_format=epoch
Set Global Variable ${JOURNAL_SINCE} ${tsnow}

Collect the suite journal
Execute Command journalctl -S @${JOURNAL_SINCE} >journal-dump.log
Get File journal-dump.log ${OUTPUT DIR}/journal-${SUITE NAME}.log

0 comments on commit 22e07b6

Please sign in to comment.