mirror of
https://github.com/oneclickvirt/ecs.git
synced 2025-12-24 12:37:53 +08:00
27 lines
613 B
Go
27 lines
613 B
Go
package tests
|
|
|
|
import (
|
|
"github.com/oneclickvirt/UnlockTests/executor"
|
|
"github.com/oneclickvirt/UnlockTests/utils"
|
|
"github.com/oneclickvirt/defaultset"
|
|
)
|
|
|
|
func MediaTest(language string) string {
|
|
var res string
|
|
readStatus := executor.ReadSelect(language, "0")
|
|
if !readStatus {
|
|
return ""
|
|
}
|
|
if executor.IPV4 {
|
|
res += defaultset.Blue("IPV4:") + "\n"
|
|
res += executor.RunTests(utils.Ipv4HttpClient, "ipv4", language, false)
|
|
return res
|
|
}
|
|
if executor.IPV6 {
|
|
res += defaultset.Blue("IPV6:") + "\n"
|
|
res += executor.RunTests(utils.Ipv6HttpClient, "ipv6", language, false)
|
|
return res
|
|
}
|
|
return ""
|
|
}
|