Fix TPM simulator initialization for tests
This commit is contained in:
parent
9a60734504
commit
a5801b3c74
1 changed files with 3 additions and 2 deletions
|
@ -49,8 +49,9 @@ func withSimulator(t *testing.T) tpm.NewTPMOption {
|
||||||
err := sim.Close()
|
err := sim.Close()
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
})
|
})
|
||||||
sim = simulator.New()
|
sim, err := simulator.New()
|
||||||
err := sim.Open()
|
require.NoError(t, err)
|
||||||
|
err = sim.Open()
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
return tpm.WithSimulator(sim)
|
return tpm.WithSimulator(sim)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue