Merge ~alfonsosanchezbeato/network-manager:test-ci into network-manager:snap-1.10

Proposed by Alfonso Sanchez-Beato
Status: Merged
Approved by: Tony Espy
Approved revision: 0f7c73da1e278c10669946e218fe73603ed29f98
Merged at revision: f1da282a92a14a98f563200f1d8e5f2d9213f5aa
Proposed branch: ~alfonsosanchezbeato/network-manager:test-ci
Merge into: network-manager:snap-1.10
Diff against target: 157 lines (+92/-16)
4 files modified
.gitignore (+4/-0)
debian/patches/disable-tests-that-fail-under-launchpad-builds.patch (+87/-0)
debian/patches/series (+1/-2)
dev/null (+0/-14)
Reviewer Review Type Date Requested Status
Tony Espy Approve
System Enablement Bot continuous-integration Approve
Review via email: mp+367987@code.launchpad.net

Commit message

snap: test for CI

Description of the change

snap: test for CI

To post a comment you must log in.
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Tony Espy (awe) wrote :

I'm not clear if this commit is temporary or not? Did you mean to check this in so that you could test your CI changes, or are these changes intended to be permanent so that we can build the snap using CI? Do we disable a similar set of tests in the old HWE nm build too?

If these changes are intended to be permanent, please add some more detail to your commit message. Something like:

snap: disable tests that fail lp builds

Some advanced integration tests (e.g. bonding, teaming, ...) that are trigged by 'make test' fail when NM is built by launchpad.

Revision history for this message
Alfonso Sanchez-Beato (alfonsosanchezbeato) wrote :

It is permanent, otherwise the snap fails the build from launchpad. Yes, we did disable a few tests in the UC16 NM snap.

I have re-worked the commit to be more specific.

Revision history for this message
Tony Espy (awe) wrote :

Thanks for the changes. LGTM!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/.gitignore b/.gitignore
2new file mode 100644
3index 0000000..2c95f33
4--- /dev/null
5+++ b/.gitignore
6@@ -0,0 +1,4 @@
7+/stage/
8+/parts/
9+/prime/
10+/snap/.snapcraft
11diff --git a/debian/patches/disable-link-bond-test.patch b/debian/patches/disable-link-bond-test.patch
12deleted file mode 100644
13index e3237d8..0000000
14--- a/debian/patches/disable-link-bond-test.patch
15+++ /dev/null
16@@ -1,14 +0,0 @@
17-Index: build/src/platform/tests/test-link.c
18-===================================================================
19---- build.orig/src/platform/tests/test-link.c
20-+++ build/src/platform/tests/test-link.c
21-@@ -475,7 +475,8 @@ test_bond (void)
22- return;
23- }
24-
25-- test_software (NM_LINK_TYPE_BOND, "bond");
26-+ g_test_skip ("Skipping test for bonding...");
27-+ /* test_software (NM_LINK_TYPE_BOND, "bond"); */
28- }
29-
30- static void
31diff --git a/debian/patches/disable-link-team-test.patch b/debian/patches/disable-link-team-test.patch
32deleted file mode 100644
33index 775c086..0000000
34--- a/debian/patches/disable-link-team-test.patch
35+++ /dev/null
36@@ -1,14 +0,0 @@
37-Index: build/src/platform/tests/test-link.c
38-===================================================================
39---- build.orig/src/platform/tests/test-link.c
40-+++ build/src/platform/tests/test-link.c
41-@@ -482,7 +482,8 @@ test_bond (void)
42- static void
43- test_team (void)
44- {
45-- test_software (NM_LINK_TYPE_TEAM, "team");
46-+ g_test_skip ("Skipping test for teaming...");
47-+ /* test_software (NM_LINK_TYPE_TEAM, "team"); */
48- }
49-
50- static void
51diff --git a/debian/patches/disable-tests-that-fail-under-launchpad-builds.patch b/debian/patches/disable-tests-that-fail-under-launchpad-builds.patch
52new file mode 100644
53index 0000000..f77ac03
54--- /dev/null
55+++ b/debian/patches/disable-tests-that-fail-under-launchpad-builds.patch
56@@ -0,0 +1,87 @@
57+diff --git a/src/devices/tests/test-arping.c b/src/devices/tests/test-arping.c
58+index bcbc1140..2de53b2b 100644
59+--- a/src/devices/tests/test-arping.c
60++++ b/src/devices/tests/test-arping.c
61+@@ -135,6 +135,9 @@ _nmtstp_init_tests (int *argc, char ***argv)
62+ void
63+ _nmtstp_setup_tests (void)
64+ {
65++ if (strstr (g_get_prgname(), "test-arping") != NULL)
66++ return;
67++
68+ g_test_add ("/arping/1", test_fixture, NULL, fixture_setup, test_arping_1, fixture_teardown);
69+ g_test_add ("/arping/2", test_fixture, NULL, fixture_setup, test_arping_2, fixture_teardown);
70+ }
71+diff --git a/src/platform/tests/test-address.c b/src/platform/tests/test-address.c
72+index 93851ff7..a6e53c83 100644
73+--- a/src/platform/tests/test-address.c
74++++ b/src/platform/tests/test-address.c
75+@@ -368,6 +368,9 @@ _nmtstp_init_tests (int *argc, char ***argv)
76+ void
77+ _nmtstp_setup_tests (void)
78+ {
79++ if (strstr (g_get_prgname(), "test-address-linux") != NULL)
80++ return;
81++
82+ #define add_test_func(testpath, test_func) nmtstp_env1_add_test_func(testpath, test_func, FALSE)
83+ add_test_func ("/address/ipv4/general", test_ip4_address_general);
84+ add_test_func ("/address/ipv6/general", test_ip6_address_general);
85+diff --git a/src/platform/tests/test-link.c b/src/platform/tests/test-link.c
86+index ef78cc24..37189d9f 100644
87+--- a/src/platform/tests/test-link.c
88++++ b/src/platform/tests/test-link.c
89+@@ -475,13 +475,15 @@ test_bond (void)
90+ return;
91+ }
92+
93+- test_software (NM_LINK_TYPE_BOND, "bond");
94++ g_test_skip ("Skipping test for bonding...");
95++ /* test_software (NM_LINK_TYPE_BOND, "bond"); */
96+ }
97+
98+ static void
99+ test_team (void)
100+ {
101+- test_software (NM_LINK_TYPE_TEAM, "team");
102++ g_test_skip ("Skipping test for teaming...");
103++ /* test_software (NM_LINK_TYPE_TEAM, "team"); */
104+ }
105+
106+ static void
107+@@ -2533,6 +2535,9 @@ _nmtstp_setup_tests (void)
108+ g_assert (!nm_platform_link_get_by_ifname (NM_PLATFORM_GET, SLAVE_NAME));
109+ g_assert (!nm_platform_link_get_by_ifname (NM_PLATFORM_GET, PARENT_NAME));
110+
111++ if (strstr (g_get_prgname(), "test-link-linux") != NULL)
112++ return;
113++
114+ g_test_add_func ("/link/bogus", test_bogus);
115+ g_test_add_func ("/link/loopback", test_loopback);
116+ g_test_add_func ("/link/internal", test_internal);
117+diff --git a/src/platform/tests/test-nmp-object.c b/src/platform/tests/test-nmp-object.c
118+index 3228de83..7f7174f5 100644
119+--- a/src/platform/tests/test-nmp-object.c
120++++ b/src/platform/tests/test-nmp-object.c
121+@@ -587,7 +587,7 @@ main (int argc, char **argv)
122+ }
123+
124+ g_test_add_func ("/nmp-object/obj-base", test_obj_base);
125+- g_test_add_func ("/nmp-object/cache_link", test_cache_link);
126++ /*g_test_add_func ("/nmp-object/cache_link", test_cache_link);*/
127+ g_test_add_func ("/nmp-object/cache_qdisc", test_cache_qdisc);
128+
129+ result = g_test_run ();
130+diff --git a/src/platform/tests/test-route.c b/src/platform/tests/test-route.c
131+index 13648f16..665a5937 100644
132+--- a/src/platform/tests/test-route.c
133++++ b/src/platform/tests/test-route.c
134+@@ -885,6 +885,9 @@ _nmtstp_init_tests (int *argc, char ***argv)
135+ void
136+ _nmtstp_setup_tests (void)
137+ {
138++ if (strstr (g_get_prgname(), "test-route-linux") != NULL)
139++ return;
140++
141+ #define add_test_func(testpath, test_func) nmtstp_env1_add_test_func(testpath, test_func, TRUE)
142+ #define add_test_func_data(testpath, test_func, arg) nmtstp_env1_add_test_func_data(testpath, test_func, arg, TRUE)
143+ add_test_func ("/route/ip4", test_ip4_route);
144diff --git a/debian/patches/series b/debian/patches/series
145index 0366f7e..0632066 100644
146--- a/debian/patches/series
147+++ b/debian/patches/series
148@@ -12,8 +12,7 @@ libnm-Check-self-still-NMManager-or-not.patch
149 Read-system-connections-from-run.patch
150 e91f1a7d2a6b8400b6b331d5b72287dcb5164a39.patch
151 Support-for-WoWLAN.patch
152-disable-link-bond-test.patch
153 disable-libnm-glib-wifi-ap-test.patch
154-disable-link-team-test.patch
155 disable-libnm-glib-test-devices-array.patch
156 add-snap-support.patch
157+disable-tests-that-fail-under-launchpad-builds.patch

Subscribers

People subscribed via source and target branches