You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: file_test.go
    path of file: ./repos/testcontainers-go
    
    the code of the file until where you have to start completion: // This test is testing very internal logic that should not be exported away from this package. We'll
// leave it in the main testcontainers package. Do not use for user facing examples.
package te
    
func Test_TarDir(t *testing.T) {
	originalSrc := filepath.Join(".", "testdata")
	tests := []struct {
		abs bool
	}{
		{
			abs: false,
		},
		{
			abs: true,
		},
	}

	for _, test := range tests {
		t.Run(fmt.Sprintf("TarDir with abs=%t", test.abs), func(t *testing.T) {
			src := originalSrc
			if test.abs {
				absSrc, err := filepath.Abs(src)
				require.NoError(t, err)

				src = absSrc
			}

			buff, err := tarDir(src, 0o755)
			if err != nil {
				t.Fatal(err)
			}

			tmpDir := filepath.Join(t.TempDir(), "subfolder")
			err = untar(tmpDir, bytes.NewReader(buff.Bytes()))
			if err != nil {
				t.Fatal(err)
			}

			srcFiles, err := os.ReadDir(src)
			if err != nil {
				log.Fatal(err)
			}

			for _, srcFile := range srcFiles {
				if srcFile.IsDir() {
					continue
				}
				srcBytes, err := os.ReadFile(filepath.Join(src, srcFile.Name()))
				if err != nil {
					t.Fatal(err)
				}

				untarBytes, err := os.ReadFile(filepath.Join(tmpDir, "testdata", srcFile.Name()))
				if err != nil {
					t.Fatal(err)
				}
				assert.Equal(t, srcBytes, untarBytes)
			}
		})
	}
}