From 2ffb9a8d7d334a17b779d1b96f1db1d001298aa0 Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Mon, 10 Jun 2019 14:32:38 -0700 Subject: Share buildDir for android/soong/android tests There is no need to create a separate buildDir for each test file, use TestMain to create a global one for the package. Test: all soong tests Change-Id: I435ee7aa88b7e0bb8ccc1ba79f82833a7accf3e9 --- android/namespace_test.go | 8 -------- 1 file changed, 8 deletions(-) (limited to 'android/namespace_test.go') diff --git a/android/namespace_test.go b/android/namespace_test.go index 9a791a534..51a0af225 100644 --- a/android/namespace_test.go +++ b/android/namespace_test.go @@ -16,8 +16,6 @@ package android import ( "errors" - "io/ioutil" - "os" "path/filepath" "reflect" "testing" @@ -613,12 +611,6 @@ func mockFiles(bps map[string]string) (files map[string][]byte) { } func setupTestFromFiles(bps map[string][]byte) (ctx *TestContext, errs []error) { - buildDir, err := ioutil.TempDir("", "soong_namespace_test") - if err != nil { - return nil, []error{err} - } - defer os.RemoveAll(buildDir) - config := TestConfig(buildDir, nil) ctx = NewTestContext() -- cgit v1.2.3-59-g8ed1b