test: remove unnecessary testing.T arg

Since the MakePluginDir function takes the TestSuite as receiver, we
don't need to additionally pass in a reference to testing.T, since the
test suite already contains one instance, and offers a function to get
it from.
pull/13032/head
Lucas Bajolet 2 years ago committed by Lucas Bajolet
parent 99f3546e32
commit c7e11f4bf2

@ -7,7 +7,7 @@ import (
func (ts *PackerTestSuite) TestLoadingOrder() {
t := ts.T()
pluginDir, cleanup := ts.MakePluginDir(t, "1.0.9", "1.0.10")
pluginDir, cleanup := ts.MakePluginDir("1.0.9", "1.0.10")
defer cleanup()
for _, command := range []string{"build", "validate"} {

@ -140,7 +140,9 @@ func currentDir() (string, error) {
// packer will be able to use that directory for running its functions.
//
// Deletion of the directory is the caller's responsibility.
func (ts *PackerTestSuite) MakePluginDir(t *testing.T, pluginVersions ...string) (pluginTempDir string, cleanup func()) {
func (ts *PackerTestSuite) MakePluginDir(pluginVersions ...string) (pluginTempDir string, cleanup func()) {
t := ts.T()
var err error
defer func() {

Loading…
Cancel
Save