]> git.ipfire.org Git - thirdparty/kea.git/commit
Changed location of unit socket in unit tests
authorMichal Nowikowski <godfryd@isc.org>
Tue, 5 Mar 2019 05:40:15 +0000 (06:40 +0100)
committerMichal Nowikowski <godfryd@isc.org>
Thu, 7 Mar 2019 09:57:33 +0000 (10:57 +0100)
commita45e2f68d7d1848adb0cf755954a3d76c9dff338
tree9aac1afd5040a2085209ff23bf56d136f8b86c8e
parent41f40b7dc68258eaf27b68980b23e69db3ac2251
Changed location of unit socket in unit tests

Previously it was stored in TEST_DATA_BUILDDIR which resides inside repo sources.
Due to the fact that when repo was located in deep patch creating socket was
failing as max socket patch is about 100 characters. Now it is located
in temp folder managed by Sandbox class. The sandbox directory is created
in test constructor and deleted in destructor. As the temp directory
is in form /tmp/kea-XXXXXX the lnegth is always lower than 1000, so running
the unit tests never fails.
12 files changed:
src/bin/agent/tests/ca_command_mgr_unittests.cc
src/bin/d2/tests/d2_command_unittest.cc
src/bin/dhcp4/tests/ctrl_dhcp4_srv_unittest.cc
src/bin/dhcp6/tests/ctrl_dhcp6_srv_unittest.cc
src/bin/netconf/tests/control_socket_unittests.cc
src/bin/netconf/tests/netconf_unittests.cc
src/lib/asiolink/tests/unix_domain_socket_unittest.cc
src/lib/config/tests/client_connection_unittests.cc
src/lib/config/tests/command_mgr_unittests.cc
src/lib/testutils/Makefile.am
src/lib/testutils/sandbox.h [new file with mode: 0644]
src/lib/util/tests/socketsession_unittest.cc