From 1c5b66957f52c1103cd5d508002a2efc0a2ad25c Mon Sep 17 00:00:00 2001 From: John Arundel Date: Sat, 20 Aug 2022 16:09:45 +0100 Subject: [PATCH] Trim '.txtar' extension from subtest name --- testscript/testdata/{nothing.txt => nothing.txtar} | 0 testscript/testdata/nothing/{nothing.txt => nothing.txtar} | 0 testscript/testscript.go | 1 + 3 files changed, 1 insertion(+) rename testscript/testdata/{nothing.txt => nothing.txtar} (100%) rename testscript/testdata/nothing/{nothing.txt => nothing.txtar} (100%) diff --git a/testscript/testdata/nothing.txt b/testscript/testdata/nothing.txtar similarity index 100% rename from testscript/testdata/nothing.txt rename to testscript/testdata/nothing.txtar diff --git a/testscript/testdata/nothing/nothing.txt b/testscript/testdata/nothing/nothing.txtar similarity index 100% rename from testscript/testdata/nothing/nothing.txt rename to testscript/testdata/nothing/nothing.txtar diff --git a/testscript/testscript.go b/testscript/testscript.go index a04ca81d..f5300f09 100644 --- a/testscript/testscript.go +++ b/testscript/testscript.go @@ -244,6 +244,7 @@ func RunT(t T, p Params) { for _, file := range files { file := file name := strings.TrimSuffix(filepath.Base(file), ".txt") + name = strings.TrimSuffix(name, ".txtar") t.Run(name, func(t T) { t.Parallel() ts := &TestScript{