From 07b22740a11632c0641657cc4dd145bd0d1e5afb Mon Sep 17 00:00:00 2001 From: Ghanan Gowripalan Date: Tue, 26 Oct 2021 12:37:43 -0700 Subject: Run packet socket tests on Fuchsia Bug: https://fxbug.dev/81592 PiperOrigin-RevId: 405710156 --- test/syscalls/linux/packet_socket.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/syscalls/linux/packet_socket.cc b/test/syscalls/linux/packet_socket.cc index c706848fc..e645f61e8 100644 --- a/test/syscalls/linux/packet_socket.cc +++ b/test/syscalls/linux/packet_socket.cc @@ -94,7 +94,9 @@ TEST_P(PacketSocketTest, GetSockName) { Eq(sizeof(addr) - sizeof(addr.sll_addr)))); EXPECT_EQ(addr.sll_family, AF_PACKET); EXPECT_EQ(addr.sll_ifindex, 0); - if (IsRunningOnGvisor() && !IsRunningWithHostinet()) { + + if (IsRunningOnGvisor() && !IsRunningWithHostinet() && + GvisorPlatform() != Platform::kFuchsia) { // TODO(https://gvisor.dev/issue/6530): Do not assume all interfaces have // an ethernet address. EXPECT_EQ(addr.sll_halen, ETH_ALEN); @@ -130,7 +132,8 @@ TEST_P(PacketSocketTest, GetSockName) { EXPECT_EQ(addr.sll_addr[i], 0) << "byte mismatch @ idx = " << i; } EXPECT_EQ(ntohs(addr.sll_protocol), htons(addr.sll_protocol)); - if (IsRunningOnGvisor() && !IsRunningWithHostinet()) { + if (IsRunningOnGvisor() && !IsRunningWithHostinet() && + GvisorPlatform() != Platform::kFuchsia) { // TODO(https://gvisor.dev/issue/6621): Support populating sll_hatype. EXPECT_EQ(addr.sll_hatype, 0); } else { -- cgit v1.2.3