Skip to content

Commit 4b725f3

Browse files
committed
chore: isort and cleanup
1 parent a3601a8 commit 4b725f3

2 files changed

Lines changed: 41 additions & 41 deletions

File tree

Lines changed: 2 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,5 @@
1+
from polywrap_core import Uri
12
from pytest import fixture
2-
from abc import ABC
3-
from typing import Any, Dict, TypeVar, Generic, List
4-
from typing import Generic, Optional, cast
5-
import pytest
6-
7-
from typing import List, Any, Dict, Union
8-
from polywrap_core import Env
9-
from polywrap_core import Uri
10-
from polywrap_core import IUriResolver, UriPackage, UriWrapper, IWrapPackage
11-
from pytest import fixture
12-
from polywrap_client_config_builder import ClientConfig
13-
from dataclasses import asdict
14-
15-
16-
# polywrap plugins
17-
18-
from polywrap_core import Invoker, InvokeOptions, InvocableResult, GetFileOptions
19-
from polywrap_result import Err, Ok, Result
20-
21-
from polywrap_core import IWrapPackage, Wrapper, GetManifestOptions
22-
from polywrap_manifest import AnyWrapManifest
23-
from polywrap_result import Ok, Result
24-
from polywrap_msgpack import msgpack_decode
25-
from polywrap_core import Uri
263

274
# Variables
285

@@ -58,8 +35,4 @@ def env_uriY():
5835

5936
@fixture
6037
def env_uriZ():
61-
return Uri("wrap://pinlist/dev.wrappers.io/Z")
62-
63-
64-
65-
38+
return Uri("wrap://pinlist/dev.wrappers.io/Z")

packages/polywrap-client-config-builder/tests/test_client_config_builder.py

Lines changed: 39 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,48 @@
1-
from abc import ABC
2-
3-
from typing import Any, Dict, TypeVar, Generic, List, Union, Optional, List, cast
1+
"""
2+
Polywrap Python Client.
3+
4+
The Test suite for the Polywrap Client Config Builder uses pytest to
5+
test the various methods of the ClientConfigBuilder class. These tests
6+
include sample code for configuring the client's:
7+
- Envs
8+
- Interfaces
9+
- Packages
10+
- Redirects
11+
- Wrappers
12+
- Resolvers
13+
14+
docs.polywrap.io
15+
Copyright 2022 Polywrap
16+
"""
417

18+
from abc import ABC
519
from dataclasses import asdict
6-
7-
from polywrap_core import IUriResolver, UriPackage, UriWrapper, IWrapPackage, AnyWrapManifest
8-
from polywrap_core import Uri
9-
from polywrap_core import Invoker, InvokeOptions, InvocableResult, GetFileOptions
10-
from polywrap_core import IWrapPackage, Wrapper, GetManifestOptions
20+
from typing import Any, Dict, Generic, List, Optional, TypeVar, Union, cast
1121

1222
from polywrap_client import PolywrapClient
13-
14-
from polywrap_client_config_builder import ClientConfigBuilder, BaseClientConfigBuilder, ClientConfig
15-
23+
from polywrap_core import (
24+
AnyWrapManifest,
25+
GetFileOptions,
26+
GetManifestOptions,
27+
InvocableResult,
28+
InvokeOptions,
29+
Invoker,
30+
IUriResolver,
31+
IWrapPackage,
32+
Uri,
33+
UriPackage,
34+
UriWrapper,
35+
Wrapper,
36+
)
1637
from polywrap_result import Err, Ok, Result
1738

18-
from polywrap_uri_resolvers import UriResolverLike
39+
from polywrap_client_config_builder import (
40+
BaseClientConfigBuilder,
41+
ClientConfig,
42+
ClientConfigBuilder,
43+
)
44+
45+
UriResolverLike = Union[Uri, UriPackage, UriWrapper, List["UriResolverLike"]]
1946

2047

2148
# Mocked Classes for the tests (class fixtures arent supported in pytest)

0 commit comments

Comments
 (0)