forked from TrueCloudLab/frostfs-sdk-go
[#47] client: Pass context to Dial() explicitly
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
bc62e2f712
commit
fa9573e857
3 changed files with 5 additions and 26 deletions
|
@ -47,11 +47,8 @@ func TestClient_DialContext(t *testing.T) {
|
|||
prm.SetServerURI("localhost:8080")
|
||||
|
||||
assert := func(ctx context.Context, errExpected error) {
|
||||
// use the particular context
|
||||
prm.SetContext(ctx)
|
||||
|
||||
// expect particular context error according to Dial docs
|
||||
require.ErrorIs(t, c.Dial(prm), errExpected)
|
||||
require.ErrorIs(t, c.Dial(ctx, prm), errExpected)
|
||||
}
|
||||
|
||||
// create pre-abandoned context
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue