Bug 1105485 - phase with ERRORs does PASS anyway
Summary: phase with ERRORs does PASS anyway
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: beakerlib
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: Petr Muller
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-06-06 09:10 UTC by Martin Žember
Modified: 2016-09-20 02:10 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-06-06 10:53:37 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
squid.conf from RHEL6 that does not work in RHEL7 and causes the service not to start (2.46 KB, text/plain)
2014-06-06 09:10 UTC, Martin Žember
no flags Details

Description Martin Žember 2014-06-06 09:10:08 UTC
Created attachment 902822 [details]
squid.conf from RHEL6 that does not work in RHEL7 and causes the service not to start

Description of problem:
Setup phase PASSes even when there are errors.

Version-Release number of selected component (if applicable):
beakerlib-1.8-1.el7

How reproducible:
Always

Steps to Reproduce:
1. put a rlServiceStart call into a phase, e.g. rlServiceStart squid
2. ensure that the service will have a problem to start, e.g. garble its configuration file (a sample configuration file for this is attached)
3. make run
4. service does not start, says ERROR, but the phase PASSes anyway

Actual results:

:: [   ERROR  ] :: rlServiceStart: Starting service squid failed
:: [   ERROR  ] :: Status of the failed service:
:: [   LOG    ] ::   Redirecting to /bin/systemctl status  squid.service
:: [   LOG    ] ::   squid.service - Squid caching proxy
:: [   LOG    ] ::   Loaded: loaded (/usr/lib/systemd/system/squid.service; disabled)
:: [   LOG    ] ::   Active: failed (Result: exit-code) since Mon 2014-06-02 21:55:57 CEST; 527ms ago
:: [   LOG    ] ::   Process: 23323 ExecStart=/usr/sbin/squid $SQUID_OPTS -f $SQUID_CONF (code=exited, status=1/FAILURE)
:: [   LOG    ] ::   Process: 23316 ExecStartPre=/usr/libexec/squid/cache_swap.sh (code=exited, status=0/SUCCESS)
:: [   LOG    ] ::   .....[snipped, reveals internal hostnames]... systemd[1]: Unit squid.service entered failed state.
:: [   LOG    ] :: Duration: 9s
:: [   LOG    ] :: Assertions: 4 good, 0 bad
:: [   PASS   ] :: RESULT: Setup

Expected results:
:: [   FAIL   ] :: RESULT: Setup


Additional info:

Comment 1 Petr Muller 2014-06-06 10:53:37 UTC
That is expected. It is intentional that no non-rlAssert* function ever directly affects the result of the phase. If the result of rlServiceX is somehow important, its RC needs to be checked with rlAssert0 or perhaps even rlRun, just as any other command.


Note You need to log in before you can comment on or make changes to this bug.