Skip to content

Commit 0fa9c7a

Browse files
committed
refactored Schema__Fast_API__Routes__Collection into better location
1 parent 4ae5cf1 commit 0fa9c7a

9 files changed

Lines changed: 32 additions & 32 deletions

osbot_fast_api/api/schemas/Schema__Fast_API__Tag__Classes_And_Routes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from typing import Set, List
2-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
2+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
33
from osbot_utils.type_safe.primitives.domains.identifiers.safe_str.Safe_Str__Id import Safe_Str__Id
44
from osbot_utils.type_safe.Type_Safe import Type_Safe
55

osbot_fast_api/api/schemas/Schema__Fast_API__Route.py renamed to osbot_fast_api/api/schemas/routes/Schema__Fast_API__Route.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
from typing import List, Type
2-
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
2+
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
33
from osbot_utils.type_safe.primitives.domains.common.safe_str.Safe_Str__Text import Safe_Str__Text
44
from osbot_fast_api.client.schemas.Schema__Endpoint__Param import Schema__Endpoint__Param
55
from osbot_utils.type_safe.Type_Safe import Type_Safe
66
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
77
from osbot_utils.type_safe.primitives.domains.identifiers.safe_str.Safe_Str__Id import Safe_Str__Id
8-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
9-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
8+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
9+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
1010

1111

1212
class Schema__Fast_API__Route(Type_Safe): # Single route information

osbot_fast_api/api/schemas/Schema__Fast_API__Routes__Collection.py renamed to osbot_fast_api/api/schemas/routes/Schema__Fast_API__Routes__Collection.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
from typing import List
2-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
3-
from osbot_utils.type_safe.Type_Safe import Type_Safe
1+
from typing import List
2+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
3+
from osbot_utils.type_safe.Type_Safe import Type_Safe
44

55

66
class Schema__Fast_API__Routes__Collection(Type_Safe): # Collection of routes

osbot_fast_api/api/schemas/routes/__init__.py

Whitespace-only changes.

osbot_fast_api/client/Fast_API__Route__Extractor.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
from typing import List, Union
22
from pydantic_core import PydanticUndefined
3-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
4-
from osbot_fast_api.api.schemas.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
5-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
3+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
4+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
5+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
66
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
77
from osbot_utils.utils.Http import url_join_safe
88
from osbot_fast_api.client.schemas.Schema__Endpoint__Param import Schema__Endpoint__Param
99
from osbot_utils.type_safe.type_safe_core.collections.Type_Safe__List import Type_Safe__List
10-
from osbot_fast_api.api.schemas.consts.consts__Fast_API import FAST_API_DEFAULT_ROUTES_PATHS
10+
from osbot_fast_api.api.schemas.consts.consts__Fast_API import FAST_API_DEFAULT_ROUTES_PATHS
1111
from osbot_utils.type_safe.Type_Safe import Type_Safe
1212
from fastapi import FastAPI
1313
from fastapi.routing import APIWebSocketRoute, APIRoute, APIRouter

tests/unit/client/test_Fast_API__Route__Extraction__integration.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
from osbot_fast_api.api.routes.Fast_API__Routes import Fast_API__Routes
1414
from osbot_fast_api.client.Fast_API__Route__Extractor import Fast_API__Route__Extractor
1515
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
16-
from osbot_fast_api.api.schemas.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
17-
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
16+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
17+
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
1818

1919

2020
class test_Fast_API__Route__Extraction__integration(TestCase): # Integration tests for complete route extraction workflow

tests/unit/client/test_Fast_API__Route__Extractor.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from fastapi import FastAPI, APIRouter, Path
55
from fastapi.routing import APIWebSocketRoute
66
from osbot_fast_api.api.decorators.route_path import route_path
7-
from osbot_fast_api.api.schemas.Schema__Fast_API__Config import Schema__Fast_API__Config
7+
from osbot_fast_api.api.schemas.Schema__Fast_API__Config import Schema__Fast_API__Config
88
from osbot_utils.type_safe.primitives.domains.identifiers.safe_str.Safe_Str__Id import Safe_Str__Id
99
from osbot_utils.testing.__ import __
1010
from osbot_fast_api.client.Fast_API__Route__Extractor import Fast_API__Route__Extractor
@@ -15,11 +15,11 @@
1515
from starlette.staticfiles import StaticFiles
1616
from osbot_fast_api.api.Fast_API import Fast_API
1717
from osbot_fast_api.api.routes.Fast_API__Routes import Fast_API__Routes
18-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
18+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
1919
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
20-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
21-
from osbot_fast_api.api.schemas.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
22-
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
20+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
21+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
22+
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
2323

2424

2525
class test_Fast_API__Route__Extractor(TestCase):

tests/unit/schemas/routes/test_Schema__Fast_API__Route.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
from osbot_utils.type_safe.Type_Safe import Type_Safe
66
from osbot_utils.type_safe.primitives.domains.identifiers.safe_str.Safe_Str__Id import Safe_Str__Id
77
from osbot_utils.utils.Objects import base_classes
8-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
9-
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
10-
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
11-
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
12-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
8+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Prefix import Safe_Str__Fast_API__Route__Prefix
9+
from osbot_fast_api.api.schemas.safe_str.Safe_Str__Fast_API__Route__Tag import Safe_Str__Fast_API__Route__Tag
10+
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
11+
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
12+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
1313

1414

1515
class test_Schema__Fast_API__Route(TestCase):

tests/unit/schemas/routes/test_Schema__Fast_API__Routes__Collection.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
from unittest import TestCase
2-
from osbot_utils.testing.__ import __
3-
from osbot_utils.type_safe.Type_Safe import Type_Safe
4-
from osbot_utils.type_safe.type_safe_core.collections.Type_Safe__List import Type_Safe__List
5-
from osbot_utils.utils.Objects import base_classes
6-
from osbot_fast_api.api.schemas.Schema__Fast_API__Route import Schema__Fast_API__Route
7-
from osbot_fast_api.api.schemas.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
8-
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
9-
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
1+
from unittest import TestCase
2+
from osbot_utils.testing.__ import __
3+
from osbot_utils.type_safe.Type_Safe import Type_Safe
4+
from osbot_utils.type_safe.type_safe_core.collections.Type_Safe__List import Type_Safe__List
5+
from osbot_utils.utils.Objects import base_classes
6+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Route import Schema__Fast_API__Route
7+
from osbot_fast_api.api.schemas.routes.Schema__Fast_API__Routes__Collection import Schema__Fast_API__Routes__Collection
8+
from osbot_utils.type_safe.primitives.domains.http.enums.Enum__Http__Method import Enum__Http__Method
9+
from osbot_fast_api.api.schemas.enums.Enum__Fast_API__Route__Type import Enum__Fast_API__Route__Type
1010

1111

1212
class test_Schema__Fast_API__Routes__Collection(TestCase):

0 commit comments

Comments
 (0)