From 69f2059e5d38bacac4bcda7912cca580ab70914d Mon Sep 17 00:00:00 2001 From: Ayush Ranjan Date: Sat, 11 Jul 2020 08:17:07 -0700 Subject: Runtime test batch executor Earlier we were docker exec-ing each test at a time. However invoking the test framework has a fixed overhead which made it infeasible to make the runtime tests run as presubmits. This change now executes tests in batches of 50 (can be altered). This really speeds up testing process. With this change, the following tests can be run in reasonable times: - Go - Nodejs - Php - Python PiperOrigin-RevId: 320763916 --- test/runtimes/proctor/python.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/runtimes/proctor/python.go') diff --git a/test/runtimes/proctor/python.go b/test/runtimes/proctor/python.go index b9e0fbe6f..7c598801b 100644 --- a/test/runtimes/proctor/python.go +++ b/test/runtimes/proctor/python.go @@ -42,8 +42,8 @@ func (pythonRunner) ListTests() ([]string, error) { return toolSlice, nil } -// TestCmd implements TestRunner.TestCmd. -func (pythonRunner) TestCmd(test string) *exec.Cmd { - args := []string{"-m", "test", test} - return exec.Command("./python", args...) +// TestCmds implements TestRunner.TestCmds. +func (pythonRunner) TestCmds(tests []string) []*exec.Cmd { + args := append([]string{"-m", "test"}, tests...) + return []*exec.Cmd{exec.Command("./python", args...)} } -- cgit v1.2.3