16 lines
236 B
V
16 lines
236 B
V
import netio
|
|
|
|
fn test_interfaces() {
|
|
ifs := netio.interfaces()!
|
|
dump(ifs)
|
|
assert ifs.len > 0
|
|
}
|
|
|
|
fn test_name_to_index() {
|
|
assert netio.name_to_index('lo')! == 1
|
|
}
|
|
|
|
fn test_index_to_name() {
|
|
assert netio.index_to_name(1)! == 'lo'
|
|
}
|