@typespec/emitter-framework 0.17.1-dev.1 → 0.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +6 -0
- package/CHANGELOG.md +8 -0
- package/dist/src/csharp/components/enum/declaration.js +3 -0
- package/dist/src/csharp/components/enum/declaration.js.map +1 -1
- package/dist/src/csharp/components/enum/declaration.test.js +28 -1
- package/dist/src/csharp/components/enum/declaration.test.js.map +1 -1
- package/dist/src/csharp/components/index.d.ts +1 -0
- package/dist/src/csharp/components/index.d.ts.map +1 -1
- package/dist/src/csharp/components/index.js +1 -0
- package/dist/src/csharp/components/index.js.map +1 -1
- package/dist/src/csharp/components/utils/index.d.ts +4 -0
- package/dist/src/csharp/components/utils/index.d.ts.map +1 -0
- package/dist/src/csharp/components/utils/index.js +4 -0
- package/dist/src/csharp/components/utils/index.js.map +1 -0
- package/dist/src/python/components/class-declaration/class-declaration.test.js +65 -17
- package/dist/src/python/components/class-declaration/class-declaration.test.js.map +1 -1
- package/dist/src/python/components/class-declaration/class-member.test.js +16 -4
- package/dist/src/python/components/class-declaration/class-member.test.js.map +1 -1
- package/dist/src/python/components/function-declaration/function-declaration.test.js +4 -1
- package/dist/src/python/components/function-declaration/function-declaration.test.js.map +1 -1
- package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.js +28 -7
- package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.js.map +1 -1
- package/dist/src/python/components/type-declaration/type-declaration.test.js +8 -2
- package/dist/src/python/components/type-declaration/type-declaration.test.js.map +1 -1
- package/package.json +17 -17
- package/package.json.bak +28 -23
- package/src/csharp/components/enum/declaration.test.tsx +26 -1
- package/src/csharp/components/enum/declaration.tsx +1 -1
- package/src/csharp/components/index.ts +1 -0
- package/src/csharp/components/utils/index.ts +3 -0
- package/src/python/components/class-declaration/class-declaration.test.tsx +65 -17
- package/src/python/components/class-declaration/class-member.test.tsx +16 -4
- package/src/python/components/function-declaration/function-declaration.test.tsx +4 -1
- package/src/python/components/type-alias-declaration/type-alias-declaration.test.tsx +28 -7
- package/src/python/components/type-declaration/type-declaration.test.tsx +8 -2
- package/vitest.config.ts +0 -4
|
@@ -37,7 +37,10 @@ describe("Python TypeDeclaration dispatcher", () => {
|
|
|
37
37
|
const output = getOutput(program, [<TypeDeclaration type={MyDate} />]);
|
|
38
38
|
expect(output).toRenderTo(d`
|
|
39
39
|
from datetime import datetime
|
|
40
|
-
from typing import
|
|
40
|
+
from typing import TYPE_CHECKING
|
|
41
|
+
|
|
42
|
+
if TYPE_CHECKING:
|
|
43
|
+
from typing import TypeAlias
|
|
41
44
|
|
|
42
45
|
|
|
43
46
|
my_date: TypeAlias = datetime`);
|
|
@@ -50,7 +53,10 @@ describe("Python TypeDeclaration dispatcher", () => {
|
|
|
50
53
|
|
|
51
54
|
const output = getOutput(program, [<TypeDeclaration type={Items} />]);
|
|
52
55
|
expect(output).toRenderTo(d`
|
|
53
|
-
from typing import
|
|
56
|
+
from typing import TYPE_CHECKING
|
|
57
|
+
|
|
58
|
+
if TYPE_CHECKING:
|
|
59
|
+
from typing import TypeAlias
|
|
54
60
|
|
|
55
61
|
|
|
56
62
|
items: TypeAlias = list[int]`);
|