blob: c0328fe1ab44981cde494a69503d284d3c4abfe0 [file] [log] [blame]
William A. Kennington IIIeac9d472020-08-03 13:57:14 -07001#include <stdplus/fd/ops.hpp>
2
Patrick Williamsd1984dd2023-05-10 16:12:44 -05003#include <gtest/gtest.h>
4
William A. Kennington IIIeac9d472020-08-03 13:57:14 -07005namespace stdplus
6{
7namespace fd
8{
9
10TEST(Flags, Flags)
11{
12 FdFlags f = FdFlags(0).set(FdFlag::CloseOnExec).unset(FdFlag::CloseOnExec);
13 f.set(FdFlag::CloseOnExec).unset(FdFlag::CloseOnExec);
14 EXPECT_EQ(0, static_cast<int>(f));
15}
16
17} // namespace fd
18} // namespace stdplus