From 44427d8e267b4c4445c1c217637d802f71e9bf52 Mon Sep 17 00:00:00 2001 From: Kevin Date: Thu, 11 Jul 2019 21:24:27 -0700 Subject: Add a stub for /dev/tty. Actual implementation to follow, but this will satisfy applications that want it to just exist. --- test/syscalls/linux/dev.cc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'test/syscalls') diff --git a/test/syscalls/linux/dev.cc b/test/syscalls/linux/dev.cc index b86ebe233..7b1dd14ef 100644 --- a/test/syscalls/linux/dev.cc +++ b/test/syscalls/linux/dev.cc @@ -13,6 +13,8 @@ // limitations under the License. #include +#include +#include #include #include @@ -143,6 +145,11 @@ TEST(DevTest, WriteDevFull) { EXPECT_THAT(WriteFd(fd.get(), "a", 1), SyscallFailsWithErrno(ENOSPC)); } +TEST(DevTest, TTYExists) { + struct stat statbuf = {}; + ASSERT_THAT(stat("/dev/tty", &statbuf), SyscallSucceeds()); +} + } // namespace } // namespace testing -- cgit v1.2.3