网络相关
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
236 B

3 years ago
  1. package network
  2. import (
  3. "fmt"
  4. "testing"
  5. )
  6. func TestScanPort(t *testing.T) {
  7. ports := ScanPort(55000, 60000, 2)
  8. fmt.Println(ports)
  9. }
  10. func TestRandPort(t *testing.T) {
  11. port := RandPort(50000, 60000)
  12. fmt.Println("port:", port)
  13. }