Require root for StartConsole Test
This test requires root to run. Skip if not root. Bug: 270052268 Test: CtsInitTestCases init#StartConsole Change-Id: I8b54acf97cda4bc2cfa15d0e34c678ec2b13f83e
This commit is contained in:
parent
22387708fc
commit
b8baa8dd34
1 changed files with 4 additions and 0 deletions
|
@ -201,6 +201,10 @@ TEST(init, StartConsole) {
|
|||
GTEST_SKIP() << "Must run on userdebug/eng builds. b/262090304";
|
||||
return;
|
||||
}
|
||||
if (getuid() != 0) {
|
||||
GTEST_SKIP() << "Must be run as root.";
|
||||
return;
|
||||
}
|
||||
std::string init_script = R"init(
|
||||
service console /system/bin/sh
|
||||
class core
|
||||
|
|
Loading…
Reference in a new issue