All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] test/py: put "Starting U-Boot" into separate log section
@ 2016-02-11 18:46 Stephen Warren
  2016-02-15  1:20 ` Simon Glass
  2016-02-15 22:37 ` [U-Boot] " Tom Rini
  0 siblings, 2 replies; 3+ messages in thread
From: Stephen Warren @ 2016-02-11 18:46 UTC (permalink / raw)
  To: u-boot

From: Stephen Warren <swarren@nvidia.com>

The initial boot of U-Boot happens within the context of the first test
that needs to access the U-Boot console when there is no existing
connection. This keeps all activity nestled within test execution, which
fits well into the pytest model. However, this mingles the U-Boot startup
logs with the execution of some test(s), which hides find the boundary
between the two.

To solve this, wrap the "Starting U-Boot" logic into a separate log
section. If the user wishes, they can simply collapse this log section
when viewing the HTML log, to concentrate purely on the test's own
interaction.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
 test/py/u_boot_console_base.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/test/py/u_boot_console_base.py b/test/py/u_boot_console_base.py
index 58575704adf5..bc2bd767e40e 100644
--- a/test/py/u_boot_console_base.py
+++ b/test/py/u_boot_console_base.py
@@ -293,8 +293,8 @@ class ConsoleBase(object):
         if self.p:
             return
         try:
+            self.log.start_section('Starting U-Boot')
             self.at_prompt = False
-            self.log.action('Starting U-Boot')
             self.p = self.get_spawn()
             # Real targets can take a long time to scroll large amounts of
             # text if LCD is enabled. This value may need tweaking in the
@@ -329,6 +329,8 @@ class ConsoleBase(object):
             self.log.error(str(ex))
             self.cleanup_spawn()
             raise
+        finally:
+            self.log.end_section('Starting U-Boot')
 
     def cleanup_spawn(self):
         """Shut down all interaction with the U-Boot instance.
-- 
2.7.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [U-Boot] [PATCH] test/py: put "Starting U-Boot" into separate log section
  2016-02-11 18:46 [U-Boot] [PATCH] test/py: put "Starting U-Boot" into separate log section Stephen Warren
@ 2016-02-15  1:20 ` Simon Glass
  2016-02-15 22:37 ` [U-Boot] " Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Simon Glass @ 2016-02-15  1:20 UTC (permalink / raw)
  To: u-boot

On 11 February 2016 at 11:46, Stephen Warren <swarren@wwwdotorg.org> wrote:
> From: Stephen Warren <swarren@nvidia.com>
>
> The initial boot of U-Boot happens within the context of the first test
> that needs to access the U-Boot console when there is no existing
> connection. This keeps all activity nestled within test execution, which
> fits well into the pytest model. However, this mingles the U-Boot startup
> logs with the execution of some test(s), which hides find the boundary
> between the two.
>
> To solve this, wrap the "Starting U-Boot" logic into a separate log
> section. If the user wishes, they can simply collapse this log section
> when viewing the HTML log, to concentrate purely on the test's own
> interaction.
>
> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> ---
>  test/py/u_boot_console_base.py | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

Acked-by: Simon Glass <sjg@chromium.org>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [U-Boot] test/py: put "Starting U-Boot" into separate log section
  2016-02-11 18:46 [U-Boot] [PATCH] test/py: put "Starting U-Boot" into separate log section Stephen Warren
  2016-02-15  1:20 ` Simon Glass
@ 2016-02-15 22:37 ` Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Tom Rini @ 2016-02-15 22:37 UTC (permalink / raw)
  To: u-boot

On Thu, Feb 11, 2016 at 11:46:12AM -0700, Stephen Warren wrote:

> From: Stephen Warren <swarren@nvidia.com>
> 
> The initial boot of U-Boot happens within the context of the first test
> that needs to access the U-Boot console when there is no existing
> connection. This keeps all activity nestled within test execution, which
> fits well into the pytest model. However, this mingles the U-Boot startup
> logs with the execution of some test(s), which hides find the boundary
> between the two.
> 
> To solve this, wrap the "Starting U-Boot" logic into a separate log
> section. If the user wishes, they can simply collapse this log section
> when viewing the HTML log, to concentrate purely on the test's own
> interaction.
> 
> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> Acked-by: Simon Glass <sjg@chromium.org>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20160215/08d3de19/attachment.sig>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-02-15 22:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-11 18:46 [U-Boot] [PATCH] test/py: put "Starting U-Boot" into separate log section Stephen Warren
2016-02-15  1:20 ` Simon Glass
2016-02-15 22:37 ` [U-Boot] " Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.