mirror of
https://github.com/tailscale/tailscale.git
synced 2025-01-05 14:57:49 +00:00
tstest/integration: add --accept-risk=all to tailscale down
The test would fail if I was running it over SSH. Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
parent
0480a925c1
commit
41dd49391f
@ -18,6 +18,7 @@
|
||||
var (
|
||||
riskTypes []string
|
||||
riskLoseSSH = registerRiskType("lose-ssh")
|
||||
riskAll = registerRiskType("all")
|
||||
)
|
||||
|
||||
func registerRiskType(riskType string) string {
|
||||
@ -35,7 +36,7 @@ func registerAcceptRiskFlag(f *flag.FlagSet, acceptedRisks *string) {
|
||||
// risks in acceptedRisks.
|
||||
func isRiskAccepted(riskType, acceptedRisks string) bool {
|
||||
for _, r := range strings.Split(acceptedRisks, ",") {
|
||||
if r == riskType {
|
||||
if r == riskType || r == riskAll {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
@ -846,7 +846,7 @@ func (n *testNode) MustUp(extraArgs ...string) {
|
||||
func (n *testNode) MustDown() {
|
||||
t := n.env.t
|
||||
t.Logf("Running down ...")
|
||||
if err := n.Tailscale("down").Run(); err != nil {
|
||||
if err := n.Tailscale("down", "--accept-risk=all").Run(); err != nil {
|
||||
t.Fatalf("down: %v", err)
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user