JOURNAL.SH(1)
πΈ JOURNAL.SH(1) β the journalling manual, bestie edition πΈ
okay so this is JOURNAL.SH(1) from the User Contributed Perl Documentation section, and it's literally the BeakerLib journalling page. i'm gonna walk you through it like we're on facetime, no cap π
β¨ NAME β¨
BeakerLib - journal - journalling functionality π
like, the whole vibe of this page is journaling. yes bestie, your test suite is getting a diary. π¦
π DESCRIPTION π
Routines for initializing the journalling features and pretty printing journal contents. that's it, that's the description β it's giving "short and iconic." β¨
π§ FUNCTIONS π§
π Journalling
rlJournalStart
Initialize the journal file. π
rlJournalStart
Run this on the very beginning of your script to initialize journalling functionality. like, top of the file, first thing, do not pass go. π
rlJournalEnd
Summarize the test run and upload the journal file. π
rlJournalEnd
Run this on the very end of your script to print summary of the whole test run, generate OUTPUTFILE and include journal in Beaker logs. so yeah β it's the closing credits of your test, and it also does the uploading and the OUTPUTFILE generation. multi-tasking queen. πΈ
rlJournalPrint
Print the content of the journal in pretty xml format. π
rlJournalPrint [type]
typeβ Can be either'raw'or'pretty', with the latter as a default. Raw: xml is in raw form, no indentation etc. Pretty: xml is pretty printed, indented, with one record per line. soprettyis the default because obviously we want the glow-up β¨
Example:
<?xml version="1.0"?>
<BEAKER_TEST>
<test_id>debugging</test_id>
<package>setup</package>
<pkgdetails>setup-2.8.9-1.fc12.noarch</pkgdetails>
<starttime>2010-02-08 15:17:47</starttime>
<endtime>2010-02-08 15:17:47</endtime>
<testname>/examples/beakerlib/Sanity/simple</testname>
<release>Fedora release 12 (Constantine)</release>
<hostname>localhost</hostname>
<arch>i686</arch>
<purpose>PURPOSE of /examples/beakerlib/Sanity/simple
Description: Minimal BeakerLib sanity test
Author: Petr Splichal <psplicha@redhat.com>
This is a minimal sanity test for BeakerLib. It contains a single
phase with a couple of asserts. We Just check that the "setup"
package is installed and that there is a sane /etc/passwd file.
</purpose>
<log>
<phase endtime="2010-02-08 15:17:47" name="Test" result="PASS"
score="0" starttime="2010-02-08 15:17:47" type="FAIL">
<test message="Checking for the presence of setup rpm">PASS</test>
<test message="File /etc/passwd should exist">PASS</test>
<test message="File '/etc/passwd' should contain 'root'">PASS</test>
</phase>
</log>
</BEAKER_TEST>
rlJournalPrintText
Print the content of the journal in pretty text format. π
rlJournalPrintText [--full-journal]
--full-journalβ The option is now deprecated, has no effect and will be removed in a future version. π«Ά so like... it's a ghost. it does nothing. it will be gone soon. don't get attached.
lowkey important: --full-journal genuinely has no effect β it's deprecated and slated for removal in a future version. it's not a secret cheat code, it's just a leftover.
Example:
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [ LOG ] :: TEST PROTOCOL
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [ LOG ] :: Test run ID : debugging
:: [ LOG ] :: Package : debugging
:: [ LOG ] :: Test started : 2010-02-08 14:45:57
:: [ LOG ] :: Test finished : 2010-02-08 14:45:58
:: [ LOG ] :: Test name :
:: [ LOG ] :: Distro: : Fedora release 12 (Constantine)
:: [ LOG ] :: Hostname : localhost
:: [ LOG ] :: Architecture : i686
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [ LOG ] :: Test description
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
PURPOSE of /examples/beakerlib/Sanity/simple
Description: Minimal BeakerLib sanity test
Author: Petr Splichal <psplicha@redhat.com>
This is a minimal sanity test for BeakerLib. It contains a single
phase with a couple of asserts. We Just check that the "setup"
package is installed and that there is a sane /etc/passwd file.
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [ LOG ] :: Test
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [ PASS ] :: Checking for the presence of setup rpm
:: [ PASS ] :: File /etc/passwd should exist
:: [ PASS ] :: File '/etc/passwd' should contain 'root'
:: [ LOG ] :: Duration: 1s
:: [ LOG ] :: Assertions: 3 good, 0 bad
:: [ PASS ] :: RESULT: Test
rlGetTestState
Returns number of failed asserts so far, or 255 if there are more than 255 failures. The variable ECODE is set to the precise number. π (so like, the return value caps out at 255, but ECODE keeps the real, exact count β iykyk)
rlGetTestState
rlGetPhaseState
Returns number of failed asserts in the current phase so far, or 255 if there are more than 255 failures. The variable ECODE is set to the precise number. same deal as above but scoped to the current phase π¦
rlGetPhaseState
π AUTHORS π
the icons who made this happen, periodt:
- Petr Muller <pmuller@redhat.com>
- Jan Hutar <jhutar@redhat.com>
- Ales Zelinka <azelinka@redhat.com>
- Petr Splichal <psplicha@redhat.com>
- Dalibor Pospisil <dapospis@redhat.com>
- Jakub Heger <jheger@redhat.com>
and that's the whole page bestie, you ate that π β¨
signing off with the deets: this was perl v5.32.1, dated 2026-04-07 β JOURNAL.SH(1), main character energy, no cap. ππ
π¦ where this page comes from
- epel 9: beakerlib 1.33.3-1.el9 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms