File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,6 +5,31 @@ menu "Network Unit Testcase"
55 bool "SAL Unit Testcase"
66 default n
77
8+ menuconfig RT_UTEST_TC_USING_NETDEV
9+ bool "netdev api test"
10+ help
11+ Enable netdev network device framework unit tests.
12+
13+ Test coverage includes:
14+ * Network connectivity (ping operations)
15+ * DHCP functionality (enable/disable/restore)
16+ * DNS configuration and hostname resolution
17+ * Interface configuration (IP/gateway/netmask)
18+ * IP address conversion functions
19+ * Device retrieval and management
20+ * Status control and callback mechanisms
21+
22+ if RT_UTEST_TC_USING_NETDEV
23+
24+ config RT_UTEST_DEFAULT_NETDEV_NAME
25+ string "Default netdev name"
26+ default "e0"
27+ help
28+ Network interface name for tests. Common values:
29+ "e0" (Ethernet), "w0" (Wireless).
30+ Ensure the device exists in your environment.
31+ endif
32+
833 menuconfig RT_UTEST_TC_USING_LWIP
934 select RT_USING_LWIP
1035 select RT_LWIP_NETIF_LOOPBACK
@@ -110,4 +135,4 @@ menu "Network Unit Testcase"
110135 This should match the actual IP of the test domain
111136
112137 endif
113- endmenu
138+ endmenu
Original file line number Diff line number Diff line change @@ -5,10 +5,17 @@ cwd = GetCurrentDir()
55src = []
66CPPPATH = [cwd ]
77
8- if GetDepend ('RT_UTEST_TC_USING_LWIP' ):
9- # Add lwIP test source if enabled
10- src += ['tc_lwip.c' ]
11- if GetDepend ('RT_UTEST_TC_USING_SAL' ):
8+ if GetDepend ('RT_UTEST_USING_ALL_CASES' ) or GetDepend ('RT_UTEST_TC_USING_LWIP' ) or GetDepend ('RT_UTEST_TC_USING_NETDEV' ):
9+
10+ if GetDepend ('RT_UTEST_TC_USING_LWIP' ):
11+ # Add lwIP test source if enabled
12+ src += ['tc_lwip.c' ]
13+
14+ if GetDepend ('RT_UTEST_TC_USING_NETDEV' ):
15+ # Add netdev test source if enabled
16+ src += ['tc_netdev.c' ]
17+
18+ if GetDepend ('RT_UTEST_TC_USING_SAL' ):
1219 src += ['tc_sal_socket.c' ]
1320
1421# Define the test group with proper dependencies
You can’t perform that action at this time.
0 commit comments