New issue
Advanced search Search tips

Issue 865791 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jul 27
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug


Participants' hotlists:
Hotlist-Tast


Sign in to add a comment

tast: Associate ARC utility functions to ARC object

Project Member Reported by nya@chromium.org, Jul 19

Issue description

CL:1143103 introduces arc.ARC object which carries several resources (e.g. logcat process).

It is suggested by derat@ that we can indicate the dependency that some functions can be called only after arc.New() is called by associate those functions to ARC struct.

For example, arc.Command can be changed like:

 func Command(...) *testexec.Cmd

to

 func (a *ARC) Command(...) *testexec.Cmd

 
Project Member

Comment 1 by bugdroid1@chromium.org, Jul 26

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform/tast-tests/+/73ff287ca018ea1420b1f8d30821adce8050b952

commit 73ff287ca018ea1420b1f8d30821adce8050b952
Author: Shuhei Takahashi <nya@chromium.org>
Date: Thu Jul 26 11:07:31 2018

arc: Convert public functions into ARC methods.

With this change, all public functions in arc package, except for
arc.New, become methods of ARC instance. This enforces arc.New to
be called before any ARC utilities.

Also:
- Make SetUpADB private and let it assume ADB is never ready.
  There is no external caller for now.
- Rename boot_phase.go to arc.go.

BUG= chromium:865791 
TEST=tast -verbose run DUT arc.Boot

Change-Id: I08367912f575def2c78555425e42506b84145496
Reviewed-on: https://chromium-review.googlesource.com/1144906
Commit-Ready: Shuhei Takahashi <nya@chromium.org>
Tested-by: Shuhei Takahashi <nya@chromium.org>
Reviewed-by: Shuhei Takahashi <nya@chromium.org>

[rename] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/arc/arc.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/arc/commands.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/arc/file.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/bundles/cros/arc/intent_forward.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/bundles/cros/arc/boot.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/bundles/cros/arc/downloads.go
[modify] https://crrev.com/73ff287ca018ea1420b1f8d30821adce8050b952/src/chromiumos/tast/local/arc/adb.go

Status: Fixed (was: Assigned)

Sign in to add a comment