go-ethereum/signer/core
Eng Zer Jun 8d066f1f42
all: use T.TempDir to create temporary test directories (#24633)
This commit replaces ioutil.TempDir with t.TempDir in tests. The
directory created by t.TempDir is automatically removed when the test
and all its subtests complete.

Prior to this commit, temporary directory created using ioutil.TempDir
had to be removed manually by calling os.RemoveAll, which is omitted in
some tests. The error handling boilerplate e.g.

	defer func() {
		if err := os.RemoveAll(dir); err != nil {
			t.Fatal(err)
		}
	}

is also tedious, but t.TempDir handles this for us nicely.

Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-04-08 15:44:55 +02:00
..
apitypes signer/core: fix complex typed data sign (EIP712) (#24220) 2022-02-08 14:40:00 +01:00
testdata core/signer, clef: improve ui-test flow, fix errors in uint handling (#19584) 2019-06-03 16:56:05 +02:00
api.go rpc: add PeerInfo (#24255) 2022-01-20 12:45:07 +01:00
api_test.go all: use T.TempDir to create temporary test directories (#24633) 2022-04-08 15:44:55 +02:00
auditlog.go signer/core: move EIP-712 types to package apitypes (#24029) 2021-12-05 14:31:41 +01:00
cliui.go cmd/clef, signer: support for eip-1559 txs in clef (#22966) 2021-06-09 13:48:47 +02:00
gnosis_safe.go signer, core: support chainId for GnosisSafeTx (#24231) 2022-01-18 13:31:25 +01:00
signed_data.go signer/core: move EIP-712 types to package apitypes (#24029) 2021-12-05 14:31:41 +01:00
signed_data_test.go signer/core: fix complex typed data sign (EIP712) (#24220) 2022-02-08 14:40:00 +01:00
stdioui.go tests, signer: remove staticcheck warnings (#20364) 2019-11-23 12:51:37 +01:00
uiapi.go all: fix typos in comments (#21118) 2020-05-25 10:21:28 +02:00
validation.go all: fix some go-critic linter warnings (#23709) 2021-10-13 17:31:02 +02:00
validation_test.go all: update author list and licenses 2019-07-22 12:17:27 +03:00