New issue
Advanced search Search tips

Issue 873952 link

Starred by 1 user

Issue metadata

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



Sign in to add a comment

Check data dep is declared in DataPath

Project Member Reported by nya@chromium.org, Aug 14

Issue description

When we attempt to use a data file without declaring it in test spec, we just see "no such file or directory" error when using the file. It's a bit confusing -- actually I was bitten a few times :( -- so I suggest checking test spec when DataPath is called.

 
Sure, doing this makes a lot of sense!
Owner: nya@chromium.org
Status: Started (was: Untriaged)
Project Member

Comment 3 by bugdroid1@chromium.org, Aug 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform/tast/+/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77

commit 33a1e7cad397b4ebfb4e287bf2e67a3c90515f77
Author: Shuhei Takahashi <nya@chromium.org>
Date: Thu Aug 16 11:25:44 2018

tast: Check data files are declared.

Make DataPath to check if a given file name is declared in Test.
Also, check the validity of file names in AddTest to catch errors
early.

This will avoid confusing "no such file or directory error" when
adding a new test because undeclared data files are not pushed to
DUT.

BUG= chromium:873952 
TEST=fast_build.sh -T
TEST=tast run DUT example.DataFiles

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

[modify] https://crrev.com/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77/src/chromiumos/tast/testing/test_test.go
[modify] https://crrev.com/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77/src/chromiumos/tast/testing/state_test.go
[modify] https://crrev.com/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77/src/chromiumos/tast/testing/registry.go
[modify] https://crrev.com/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77/src/chromiumos/tast/testing/state.go
[modify] https://crrev.com/33a1e7cad397b4ebfb4e287bf2e67a3c90515f77/src/chromiumos/tast/testing/test.go

Status: Fixed (was: Started)

Sign in to add a comment