@goast/typescript 0.4.4 → 0.5.1-k6.1
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/LICENSE +21 -21
- package/README.md +52 -52
- package/assets/client/angular/angular-service.utils.ts +82 -82
- package/assets/client/angular/request-builder.ts +377 -377
- package/assets/client/fetch/fetch-client.utils.ts +52 -52
- package/assets/client/k6/request-builder.js +419 -418
- package/assets/client/k6/request-builder.ts +341 -0
- package/assets/stubs/easy-network-stub/easy-network-stub.utils.ts +259 -259
- package/esm/src/file-builder.js +1 -1
- package/esm/src/generators/services/angular-services/angular-service-generator.d.ts +1 -0
- package/esm/src/generators/services/angular-services/angular-service-generator.d.ts.map +1 -1
- package/esm/src/generators/services/angular-services/angular-service-generator.js +31 -30
- package/esm/src/generators/services/angular-services/models.d.ts +6 -1
- package/esm/src/generators/services/angular-services/models.d.ts.map +1 -1
- package/esm/src/generators/services/angular-services/models.js +2 -1
- package/esm/src/generators/services/easy-network-stub/easy-network-stub-generator.js +9 -9
- package/esm/src/generators/services/fetch-clients/fetch-client-generator.js +2 -2
- package/esm/src/generators/services/k6-clients/k6-client-generator.d.ts +2 -2
- package/esm/src/generators/services/k6-clients/k6-client-generator.d.ts.map +1 -1
- package/esm/src/generators/services/k6-clients/k6-client-generator.js +109 -57
- package/esm/src/generators/services/k6-clients/k6-clients-generator.d.ts.map +1 -1
- package/esm/src/generators/services/k6-clients/k6-clients-generator.js +5 -2
- package/esm/src/generators/services/k6-clients/models.d.ts +5 -0
- package/esm/src/generators/services/k6-clients/models.d.ts.map +1 -1
- package/esm/src/generators/services/k6-clients/models.js +1 -1
- package/esm/src/generators/services/k6-clients/refs.d.ts.map +1 -1
- package/esm/src/generators/services/k6-clients/refs.js +2 -1
- package/package.json +2 -5
- package/script/src/file-builder.js +1 -1
- package/script/src/generators/services/angular-services/angular-service-generator.d.ts +1 -0
- package/script/src/generators/services/angular-services/angular-service-generator.d.ts.map +1 -1
- package/script/src/generators/services/angular-services/angular-service-generator.js +31 -30
- package/script/src/generators/services/angular-services/models.d.ts +6 -1
- package/script/src/generators/services/angular-services/models.d.ts.map +1 -1
- package/script/src/generators/services/angular-services/models.js +2 -1
- package/script/src/generators/services/easy-network-stub/easy-network-stub-generator.js +9 -9
- package/script/src/generators/services/fetch-clients/fetch-client-generator.js +2 -2
- package/script/src/generators/services/k6-clients/k6-client-generator.d.ts +2 -2
- package/script/src/generators/services/k6-clients/k6-client-generator.d.ts.map +1 -1
- package/script/src/generators/services/k6-clients/k6-client-generator.js +109 -57
- package/script/src/generators/services/k6-clients/k6-clients-generator.d.ts.map +1 -1
- package/script/src/generators/services/k6-clients/k6-clients-generator.js +5 -2
- package/script/src/generators/services/k6-clients/models.d.ts +5 -0
- package/script/src/generators/services/k6-clients/models.d.ts.map +1 -1
- package/script/src/generators/services/k6-clients/models.js +1 -1
- package/script/src/generators/services/k6-clients/refs.d.ts.map +1 -1
- package/script/src/generators/services/k6-clients/refs.js +2 -1
- package/esm/_dnt.test_polyfills.d.ts +0 -29
- package/esm/_dnt.test_polyfills.d.ts.map +0 -1
- package/esm/_dnt.test_polyfills.js +0 -31
- package/esm/_dnt.test_shims.d.ts +0 -6
- package/esm/_dnt.test_shims.d.ts.map +0 -1
- package/esm/_dnt.test_shims.js +0 -61
- package/esm/deps/jsr.io/@std/assert/1.0.11/assertion_error.d.ts +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.11/assertion_error.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/assertion_error.js +0 -30
- package/esm/deps/jsr.io/@std/assert/1.0.11/equal.d.ts +0 -17
- package/esm/deps/jsr.io/@std/assert/1.0.11/equal.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/equal.js +0 -183
- package/esm/deps/jsr.io/@std/assert/1.0.11/equals.d.ts +0 -35
- package/esm/deps/jsr.io/@std/assert/1.0.11/equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/equals.js +0 -58
- package/esm/deps/jsr.io/@std/assert/1.0.11/false.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.11/false.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/false.js +0 -22
- package/esm/deps/jsr.io/@std/assert/1.0.11/instance_of.d.ts +0 -23
- package/esm/deps/jsr.io/@std/assert/1.0.11/instance_of.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/instance_of.js +0 -53
- package/esm/deps/jsr.io/@std/assert/1.0.11/is_error.d.ts +0 -25
- package/esm/deps/jsr.io/@std/assert/1.0.11/is_error.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/is_error.js +0 -54
- package/esm/deps/jsr.io/@std/assert/1.0.11/match.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.11/match.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/match.js +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_instance_of.d.ts +0 -20
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_instance_of.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_instance_of.js +0 -29
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_match.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_match.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_match.js +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.d.ts +0 -23
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.js +0 -32
- package/esm/deps/jsr.io/@std/assert/1.0.11/rejects.d.ts +0 -42
- package/esm/deps/jsr.io/@std/assert/1.0.11/rejects.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/rejects.js +0 -53
- package/esm/deps/jsr.io/@std/assert/1.0.11/strict_equals.d.ts +0 -24
- package/esm/deps/jsr.io/@std/assert/1.0.11/strict_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.11/strict_equals.js +0 -57
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_equals.d.ts +0 -20
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_equals.js +0 -29
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.d.ts +0 -14
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.js +0 -43
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.d.ts +0 -17
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.js +0 -26
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assertions.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assertions.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_assertions.js +0 -13
- package/esm/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.d.ts +0 -46
- package/esm/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.js +0 -161
- package/esm/deps/jsr.io/@std/expect/1.0.12/_build_message.d.ts +0 -6
- package/esm/deps/jsr.io/@std/expect/1.0.12/_build_message.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_build_message.js +0 -29
- package/esm/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.js +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.12/_equal.d.ts +0 -9
- package/esm/deps/jsr.io/@std/expect/1.0.12/_equal.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_equal.js +0 -191
- package/esm/deps/jsr.io/@std/expect/1.0.12/_extend.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.12/_extend.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_extend.js +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.12/_inspect_args.d.ts +0 -3
- package/esm/deps/jsr.io/@std/expect/1.0.12/_inspect_args.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_inspect_args.js +0 -12
- package/esm/deps/jsr.io/@std/expect/1.0.12/_matchers.d.ts +0 -34
- package/esm/deps/jsr.io/@std/expect/1.0.12/_matchers.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_matchers.js +0 -714
- package/esm/deps/jsr.io/@std/expect/1.0.12/_mock_util.d.ts +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.12/_mock_util.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_mock_util.js +0 -10
- package/esm/deps/jsr.io/@std/expect/1.0.12/_serializer.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.12/_serializer.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_serializer.js +0 -10
- package/esm/deps/jsr.io/@std/expect/1.0.12/_types.d.ts +0 -843
- package/esm/deps/jsr.io/@std/expect/1.0.12/_types.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_types.js +0 -3
- package/esm/deps/jsr.io/@std/expect/1.0.12/_utils.d.ts +0 -9
- package/esm/deps/jsr.io/@std/expect/1.0.12/_utils.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/_utils.js +0 -218
- package/esm/deps/jsr.io/@std/expect/1.0.12/expect.d.ts +0 -60
- package/esm/deps/jsr.io/@std/expect/1.0.12/expect.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/expect.js +0 -523
- package/esm/deps/jsr.io/@std/expect/1.0.12/fn.d.ts +0 -29
- package/esm/deps/jsr.io/@std/expect/1.0.12/fn.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/fn.js +0 -85
- package/esm/deps/jsr.io/@std/expect/1.0.12/mod.d.ts +0 -86
- package/esm/deps/jsr.io/@std/expect/1.0.12/mod.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.12/mod.js +0 -88
- package/esm/deps/jsr.io/@std/internal/1.0.5/assertion_state.d.ts +0 -160
- package/esm/deps/jsr.io/@std/internal/1.0.5/assertion_state.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/assertion_state.js +0 -199
- package/esm/deps/jsr.io/@std/internal/1.0.5/build_message.d.ts +0 -82
- package/esm/deps/jsr.io/@std/internal/1.0.5/build_message.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/build_message.js +0 -111
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff.d.ts +0 -140
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff.js +0 -277
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff_str.d.ts +0 -99
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff_str.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/diff_str.js +0 -180
- package/esm/deps/jsr.io/@std/internal/1.0.5/format.d.ts +0 -2
- package/esm/deps/jsr.io/@std/internal/1.0.5/format.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/format.js +0 -37
- package/esm/deps/jsr.io/@std/internal/1.0.5/styles.d.ts +0 -159
- package/esm/deps/jsr.io/@std/internal/1.0.5/styles.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/styles.js +0 -207
- package/esm/deps/jsr.io/@std/internal/1.0.5/types.d.ts +0 -16
- package/esm/deps/jsr.io/@std/internal/1.0.5/types.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.5/types.js +0 -2
- package/esm/deps/jsr.io/@std/testing/1.0.9/_mock_utils.d.ts +0 -15
- package/esm/deps/jsr.io/@std/testing/1.0.9/_mock_utils.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.9/_mock_utils.js +0 -35
- package/esm/deps/jsr.io/@std/testing/1.0.9/_test_suite.d.ts +0 -79
- package/esm/deps/jsr.io/@std/testing/1.0.9/_test_suite.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.9/_test_suite.js +0 -380
- package/esm/deps/jsr.io/@std/testing/1.0.9/bdd.d.ts +0 -738
- package/esm/deps/jsr.io/@std/testing/1.0.9/bdd.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.9/bdd.js +0 -654
- package/esm/deps/jsr.io/@std/testing/1.0.9/mock.d.ts +0 -674
- package/esm/deps/jsr.io/@std/testing/1.0.9/mock.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.9/mock.js +0 -1083
- package/esm/src/ast/nodes/argument.test.d.ts +0 -2
- package/esm/src/ast/nodes/argument.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/argument.test.js +0 -34
- package/esm/src/ast/nodes/array-type.test.d.ts +0 -2
- package/esm/src/ast/nodes/array-type.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/array-type.test.js +0 -26
- package/esm/src/ast/nodes/arrow-function.test.d.ts +0 -2
- package/esm/src/ast/nodes/arrow-function.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/arrow-function.test.js +0 -62
- package/esm/src/ast/nodes/class.test.d.ts +0 -2
- package/esm/src/ast/nodes/class.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/class.test.js +0 -150
- package/esm/src/ast/nodes/constructor-parameter.test.d.ts +0 -2
- package/esm/src/ast/nodes/constructor-parameter.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/constructor-parameter.test.js +0 -99
- package/esm/src/ast/nodes/constructor.test.d.ts +0 -2
- package/esm/src/ast/nodes/constructor.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/constructor.test.js +0 -102
- package/esm/src/ast/nodes/decorator.test.d.ts +0 -2
- package/esm/src/ast/nodes/decorator.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/decorator.test.js +0 -47
- package/esm/src/ast/nodes/doc-tag.test.d.ts +0 -2
- package/esm/src/ast/nodes/doc-tag.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/doc-tag.test.js +0 -30
- package/esm/src/ast/nodes/doc.test.d.ts +0 -2
- package/esm/src/ast/nodes/doc.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/doc.test.js +0 -31
- package/esm/src/ast/nodes/enum-value.test.d.ts +0 -2
- package/esm/src/ast/nodes/enum-value.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/enum-value.test.js +0 -52
- package/esm/src/ast/nodes/enum.test.d.ts +0 -2
- package/esm/src/ast/nodes/enum.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/enum.test.js +0 -66
- package/esm/src/ast/nodes/export.test.d.ts +0 -2
- package/esm/src/ast/nodes/export.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/export.test.js +0 -22
- package/esm/src/ast/nodes/function-type.test.d.ts +0 -2
- package/esm/src/ast/nodes/function-type.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/function-type.test.js +0 -48
- package/esm/src/ast/nodes/function.test.d.ts +0 -2
- package/esm/src/ast/nodes/function.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/function.test.js +0 -108
- package/esm/src/ast/nodes/generic-parameter.test.d.ts +0 -2
- package/esm/src/ast/nodes/generic-parameter.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/generic-parameter.test.js +0 -70
- package/esm/src/ast/nodes/indexer.test.d.ts +0 -2
- package/esm/src/ast/nodes/indexer.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/indexer.test.js +0 -32
- package/esm/src/ast/nodes/interface.test.d.ts +0 -2
- package/esm/src/ast/nodes/interface.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/interface.test.js +0 -115
- package/esm/src/ast/nodes/intersection-type.test.d.ts +0 -2
- package/esm/src/ast/nodes/intersection-type.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/intersection-type.test.js +0 -38
- package/esm/src/ast/nodes/method.test.d.ts +0 -2
- package/esm/src/ast/nodes/method.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/method.test.js +0 -148
- package/esm/src/ast/nodes/object-type.test.d.ts +0 -2
- package/esm/src/ast/nodes/object-type.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/object-type.test.js +0 -30
- package/esm/src/ast/nodes/object.test.d.ts +0 -2
- package/esm/src/ast/nodes/object.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/object.test.js +0 -30
- package/esm/src/ast/nodes/parameter.test.d.ts +0 -2
- package/esm/src/ast/nodes/parameter.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/parameter.test.js +0 -71
- package/esm/src/ast/nodes/property-accessor.test.d.ts +0 -2
- package/esm/src/ast/nodes/property-accessor.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/property-accessor.test.js +0 -102
- package/esm/src/ast/nodes/property.test.d.ts +0 -2
- package/esm/src/ast/nodes/property.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/property.test.js +0 -89
- package/esm/src/ast/nodes/reference.test.d.ts +0 -2
- package/esm/src/ast/nodes/reference.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/reference.test.js +0 -31
- package/esm/src/ast/nodes/string.test.d.ts +0 -2
- package/esm/src/ast/nodes/string.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/string.test.js +0 -28
- package/esm/src/ast/nodes/tuple.test.d.ts +0 -2
- package/esm/src/ast/nodes/tuple.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/tuple.test.js +0 -33
- package/esm/src/ast/nodes/type-alias.test.d.ts +0 -2
- package/esm/src/ast/nodes/type-alias.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/type-alias.test.js +0 -27
- package/esm/src/ast/nodes/union-type.test.d.ts +0 -2
- package/esm/src/ast/nodes/union-type.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/union-type.test.js +0 -38
- package/esm/src/ast/nodes/variable.test.d.ts +0 -2
- package/esm/src/ast/nodes/variable.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/variable.test.js +0 -38
- package/esm/src/import-collection.test.d.ts +0 -2
- package/esm/src/import-collection.test.d.ts.map +0 -1
- package/esm/src/import-collection.test.js +0 -64
- package/esm/tests/openapi-models.test.d.ts +0 -2
- package/esm/tests/openapi-models.test.d.ts.map +0 -1
- package/esm/tests/openapi-models.test.js +0 -45
- package/script/_dnt.test_polyfills.d.ts +0 -29
- package/script/_dnt.test_polyfills.d.ts.map +0 -1
- package/script/_dnt.test_polyfills.js +0 -32
- package/script/_dnt.test_shims.d.ts +0 -6
- package/script/_dnt.test_shims.d.ts.map +0 -1
- package/script/_dnt.test_shims.js +0 -65
- package/script/deps/jsr.io/@std/assert/1.0.11/assertion_error.d.ts +0 -26
- package/script/deps/jsr.io/@std/assert/1.0.11/assertion_error.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/assertion_error.js +0 -34
- package/script/deps/jsr.io/@std/assert/1.0.11/equal.d.ts +0 -17
- package/script/deps/jsr.io/@std/assert/1.0.11/equal.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/equal.js +0 -187
- package/script/deps/jsr.io/@std/assert/1.0.11/equals.d.ts +0 -35
- package/script/deps/jsr.io/@std/assert/1.0.11/equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/equals.js +0 -61
- package/script/deps/jsr.io/@std/assert/1.0.11/false.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.11/false.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/false.js +0 -25
- package/script/deps/jsr.io/@std/assert/1.0.11/instance_of.d.ts +0 -23
- package/script/deps/jsr.io/@std/assert/1.0.11/instance_of.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/instance_of.js +0 -56
- package/script/deps/jsr.io/@std/assert/1.0.11/is_error.d.ts +0 -25
- package/script/deps/jsr.io/@std/assert/1.0.11/is_error.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/is_error.js +0 -57
- package/script/deps/jsr.io/@std/assert/1.0.11/match.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.11/match.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/match.js +0 -29
- package/script/deps/jsr.io/@std/assert/1.0.11/not_instance_of.d.ts +0 -20
- package/script/deps/jsr.io/@std/assert/1.0.11/not_instance_of.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/not_instance_of.js +0 -32
- package/script/deps/jsr.io/@std/assert/1.0.11/not_match.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.11/not_match.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/not_match.js +0 -29
- package/script/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.d.ts +0 -23
- package/script/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.js +0 -35
- package/script/deps/jsr.io/@std/assert/1.0.11/rejects.d.ts +0 -42
- package/script/deps/jsr.io/@std/assert/1.0.11/rejects.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/rejects.js +0 -56
- package/script/deps/jsr.io/@std/assert/1.0.11/strict_equals.d.ts +0 -24
- package/script/deps/jsr.io/@std/assert/1.0.11/strict_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.11/strict_equals.js +0 -60
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_equals.d.ts +0 -20
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_equals.js +0 -32
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.d.ts +0 -14
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.js +0 -46
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.d.ts +0 -17
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.js +0 -29
- package/script/deps/jsr.io/@std/expect/1.0.12/_assertions.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.12/_assertions.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_assertions.js +0 -18
- package/script/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.d.ts +0 -46
- package/script/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.js +0 -183
- package/script/deps/jsr.io/@std/expect/1.0.12/_build_message.d.ts +0 -6
- package/script/deps/jsr.io/@std/expect/1.0.12/_build_message.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_build_message.js +0 -33
- package/script/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.js +0 -15
- package/script/deps/jsr.io/@std/expect/1.0.12/_equal.d.ts +0 -9
- package/script/deps/jsr.io/@std/expect/1.0.12/_equal.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_equal.js +0 -194
- package/script/deps/jsr.io/@std/expect/1.0.12/_extend.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.12/_extend.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_extend.js +0 -15
- package/script/deps/jsr.io/@std/expect/1.0.12/_inspect_args.d.ts +0 -3
- package/script/deps/jsr.io/@std/expect/1.0.12/_inspect_args.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_inspect_args.js +0 -17
- package/script/deps/jsr.io/@std/expect/1.0.12/_matchers.d.ts +0 -34
- package/script/deps/jsr.io/@std/expect/1.0.12/_matchers.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_matchers.js +0 -748
- package/script/deps/jsr.io/@std/expect/1.0.12/_mock_util.d.ts +0 -11
- package/script/deps/jsr.io/@std/expect/1.0.12/_mock_util.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_mock_util.js +0 -14
- package/script/deps/jsr.io/@std/expect/1.0.12/_serializer.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.12/_serializer.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_serializer.js +0 -14
- package/script/deps/jsr.io/@std/expect/1.0.12/_types.d.ts +0 -843
- package/script/deps/jsr.io/@std/expect/1.0.12/_types.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_types.js +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.12/_utils.d.ts +0 -9
- package/script/deps/jsr.io/@std/expect/1.0.12/_utils.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/_utils.js +0 -226
- package/script/deps/jsr.io/@std/expect/1.0.12/expect.d.ts +0 -60
- package/script/deps/jsr.io/@std/expect/1.0.12/expect.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/expect.js +0 -527
- package/script/deps/jsr.io/@std/expect/1.0.12/fn.d.ts +0 -29
- package/script/deps/jsr.io/@std/expect/1.0.12/fn.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/fn.js +0 -88
- package/script/deps/jsr.io/@std/expect/1.0.12/mod.d.ts +0 -86
- package/script/deps/jsr.io/@std/expect/1.0.12/mod.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.12/mod.js +0 -91
- package/script/deps/jsr.io/@std/internal/1.0.5/assertion_state.d.ts +0 -160
- package/script/deps/jsr.io/@std/internal/1.0.5/assertion_state.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/assertion_state.js +0 -204
- package/script/deps/jsr.io/@std/internal/1.0.5/build_message.d.ts +0 -82
- package/script/deps/jsr.io/@std/internal/1.0.5/build_message.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/build_message.js +0 -116
- package/script/deps/jsr.io/@std/internal/1.0.5/diff.d.ts +0 -140
- package/script/deps/jsr.io/@std/internal/1.0.5/diff.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/diff.js +0 -284
- package/script/deps/jsr.io/@std/internal/1.0.5/diff_str.d.ts +0 -99
- package/script/deps/jsr.io/@std/internal/1.0.5/diff_str.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/diff_str.js +0 -186
- package/script/deps/jsr.io/@std/internal/1.0.5/format.d.ts +0 -2
- package/script/deps/jsr.io/@std/internal/1.0.5/format.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/format.js +0 -41
- package/script/deps/jsr.io/@std/internal/1.0.5/styles.d.ts +0 -159
- package/script/deps/jsr.io/@std/internal/1.0.5/styles.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/styles.js +0 -220
- package/script/deps/jsr.io/@std/internal/1.0.5/types.d.ts +0 -16
- package/script/deps/jsr.io/@std/internal/1.0.5/types.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/internal/1.0.5/types.js +0 -3
- package/script/deps/jsr.io/@std/testing/1.0.9/_mock_utils.d.ts +0 -15
- package/script/deps/jsr.io/@std/testing/1.0.9/_mock_utils.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.9/_mock_utils.js +0 -41
- package/script/deps/jsr.io/@std/testing/1.0.9/_test_suite.d.ts +0 -79
- package/script/deps/jsr.io/@std/testing/1.0.9/_test_suite.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.9/_test_suite.js +0 -385
- package/script/deps/jsr.io/@std/testing/1.0.9/bdd.d.ts +0 -738
- package/script/deps/jsr.io/@std/testing/1.0.9/bdd.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.9/bdd.js +0 -665
- package/script/deps/jsr.io/@std/testing/1.0.9/mock.d.ts +0 -674
- package/script/deps/jsr.io/@std/testing/1.0.9/mock.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.9/mock.js +0 -1102
- package/script/src/ast/nodes/argument.test.d.ts +0 -2
- package/script/src/ast/nodes/argument.test.d.ts.map +0 -1
- package/script/src/ast/nodes/argument.test.js +0 -36
- package/script/src/ast/nodes/array-type.test.d.ts +0 -2
- package/script/src/ast/nodes/array-type.test.d.ts.map +0 -1
- package/script/src/ast/nodes/array-type.test.js +0 -28
- package/script/src/ast/nodes/arrow-function.test.d.ts +0 -2
- package/script/src/ast/nodes/arrow-function.test.d.ts.map +0 -1
- package/script/src/ast/nodes/arrow-function.test.js +0 -64
- package/script/src/ast/nodes/class.test.d.ts +0 -2
- package/script/src/ast/nodes/class.test.d.ts.map +0 -1
- package/script/src/ast/nodes/class.test.js +0 -152
- package/script/src/ast/nodes/constructor-parameter.test.d.ts +0 -2
- package/script/src/ast/nodes/constructor-parameter.test.d.ts.map +0 -1
- package/script/src/ast/nodes/constructor-parameter.test.js +0 -101
- package/script/src/ast/nodes/constructor.test.d.ts +0 -2
- package/script/src/ast/nodes/constructor.test.d.ts.map +0 -1
- package/script/src/ast/nodes/constructor.test.js +0 -104
- package/script/src/ast/nodes/decorator.test.d.ts +0 -2
- package/script/src/ast/nodes/decorator.test.d.ts.map +0 -1
- package/script/src/ast/nodes/decorator.test.js +0 -49
- package/script/src/ast/nodes/doc-tag.test.d.ts +0 -2
- package/script/src/ast/nodes/doc-tag.test.d.ts.map +0 -1
- package/script/src/ast/nodes/doc-tag.test.js +0 -32
- package/script/src/ast/nodes/doc.test.d.ts +0 -2
- package/script/src/ast/nodes/doc.test.d.ts.map +0 -1
- package/script/src/ast/nodes/doc.test.js +0 -33
- package/script/src/ast/nodes/enum-value.test.d.ts +0 -2
- package/script/src/ast/nodes/enum-value.test.d.ts.map +0 -1
- package/script/src/ast/nodes/enum-value.test.js +0 -54
- package/script/src/ast/nodes/enum.test.d.ts +0 -2
- package/script/src/ast/nodes/enum.test.d.ts.map +0 -1
- package/script/src/ast/nodes/enum.test.js +0 -68
- package/script/src/ast/nodes/export.test.d.ts +0 -2
- package/script/src/ast/nodes/export.test.d.ts.map +0 -1
- package/script/src/ast/nodes/export.test.js +0 -24
- package/script/src/ast/nodes/function-type.test.d.ts +0 -2
- package/script/src/ast/nodes/function-type.test.d.ts.map +0 -1
- package/script/src/ast/nodes/function-type.test.js +0 -50
- package/script/src/ast/nodes/function.test.d.ts +0 -2
- package/script/src/ast/nodes/function.test.d.ts.map +0 -1
- package/script/src/ast/nodes/function.test.js +0 -110
- package/script/src/ast/nodes/generic-parameter.test.d.ts +0 -2
- package/script/src/ast/nodes/generic-parameter.test.d.ts.map +0 -1
- package/script/src/ast/nodes/generic-parameter.test.js +0 -72
- package/script/src/ast/nodes/indexer.test.d.ts +0 -2
- package/script/src/ast/nodes/indexer.test.d.ts.map +0 -1
- package/script/src/ast/nodes/indexer.test.js +0 -34
- package/script/src/ast/nodes/interface.test.d.ts +0 -2
- package/script/src/ast/nodes/interface.test.d.ts.map +0 -1
- package/script/src/ast/nodes/interface.test.js +0 -117
- package/script/src/ast/nodes/intersection-type.test.d.ts +0 -2
- package/script/src/ast/nodes/intersection-type.test.d.ts.map +0 -1
- package/script/src/ast/nodes/intersection-type.test.js +0 -40
- package/script/src/ast/nodes/method.test.d.ts +0 -2
- package/script/src/ast/nodes/method.test.d.ts.map +0 -1
- package/script/src/ast/nodes/method.test.js +0 -150
- package/script/src/ast/nodes/object-type.test.d.ts +0 -2
- package/script/src/ast/nodes/object-type.test.d.ts.map +0 -1
- package/script/src/ast/nodes/object-type.test.js +0 -32
- package/script/src/ast/nodes/object.test.d.ts +0 -2
- package/script/src/ast/nodes/object.test.d.ts.map +0 -1
- package/script/src/ast/nodes/object.test.js +0 -32
- package/script/src/ast/nodes/parameter.test.d.ts +0 -2
- package/script/src/ast/nodes/parameter.test.d.ts.map +0 -1
- package/script/src/ast/nodes/parameter.test.js +0 -73
- package/script/src/ast/nodes/property-accessor.test.d.ts +0 -2
- package/script/src/ast/nodes/property-accessor.test.d.ts.map +0 -1
- package/script/src/ast/nodes/property-accessor.test.js +0 -104
- package/script/src/ast/nodes/property.test.d.ts +0 -2
- package/script/src/ast/nodes/property.test.d.ts.map +0 -1
- package/script/src/ast/nodes/property.test.js +0 -91
- package/script/src/ast/nodes/reference.test.d.ts +0 -2
- package/script/src/ast/nodes/reference.test.d.ts.map +0 -1
- package/script/src/ast/nodes/reference.test.js +0 -33
- package/script/src/ast/nodes/string.test.d.ts +0 -2
- package/script/src/ast/nodes/string.test.d.ts.map +0 -1
- package/script/src/ast/nodes/string.test.js +0 -30
- package/script/src/ast/nodes/tuple.test.d.ts +0 -2
- package/script/src/ast/nodes/tuple.test.d.ts.map +0 -1
- package/script/src/ast/nodes/tuple.test.js +0 -35
- package/script/src/ast/nodes/type-alias.test.d.ts +0 -2
- package/script/src/ast/nodes/type-alias.test.d.ts.map +0 -1
- package/script/src/ast/nodes/type-alias.test.js +0 -29
- package/script/src/ast/nodes/union-type.test.d.ts +0 -2
- package/script/src/ast/nodes/union-type.test.d.ts.map +0 -1
- package/script/src/ast/nodes/union-type.test.js +0 -40
- package/script/src/ast/nodes/variable.test.d.ts +0 -2
- package/script/src/ast/nodes/variable.test.d.ts.map +0 -1
- package/script/src/ast/nodes/variable.test.js +0 -40
- package/script/src/import-collection.test.d.ts +0 -2
- package/script/src/import-collection.test.d.ts.map +0 -1
- package/script/src/import-collection.test.js +0 -66
- package/script/tests/openapi-models.test.d.ts +0 -2
- package/script/tests/openapi-models.test.d.ts.map +0 -1
- package/script/tests/openapi-models.test.js +0 -48
- package/src/_dnt.test_polyfills.ts +0 -70
- package/src/_dnt.test_shims.ts +0 -64
- package/src/deps/jsr.io/@std/assert/1.0.11/assertion_error.ts +0 -31
- package/src/deps/jsr.io/@std/assert/1.0.11/equal.ts +0 -210
- package/src/deps/jsr.io/@std/assert/1.0.11/equals.ts +0 -65
- package/src/deps/jsr.io/@std/assert/1.0.11/false.ts +0 -26
- package/src/deps/jsr.io/@std/assert/1.0.11/instance_of.ts +0 -64
- package/src/deps/jsr.io/@std/assert/1.0.11/is_error.ts +0 -65
- package/src/deps/jsr.io/@std/assert/1.0.11/match.ts +0 -30
- package/src/deps/jsr.io/@std/assert/1.0.11/not_instance_of.ts +0 -33
- package/src/deps/jsr.io/@std/assert/1.0.11/not_match.ts +0 -30
- package/src/deps/jsr.io/@std/assert/1.0.11/not_strict_equals.ts +0 -42
- package/src/deps/jsr.io/@std/assert/1.0.11/rejects.ts +0 -123
- package/src/deps/jsr.io/@std/assert/1.0.11/strict_equals.ts +0 -67
- package/src/deps/jsr.io/@std/expect/1.0.12/_assert_equals.ts +0 -38
- package/src/deps/jsr.io/@std/expect/1.0.12/_assert_is_error.ts +0 -54
- package/src/deps/jsr.io/@std/expect/1.0.12/_assert_not_equals.ts +0 -35
- package/src/deps/jsr.io/@std/expect/1.0.12/_assertions.ts +0 -18
- package/src/deps/jsr.io/@std/expect/1.0.12/_asymmetric_matchers.ts +0 -198
- package/src/deps/jsr.io/@std/expect/1.0.12/_build_message.ts +0 -51
- package/src/deps/jsr.io/@std/expect/1.0.12/_custom_equality_tester.ts +0 -19
- package/src/deps/jsr.io/@std/expect/1.0.12/_equal.ts +0 -230
- package/src/deps/jsr.io/@std/expect/1.0.12/_extend.ts +0 -16
- package/src/deps/jsr.io/@std/expect/1.0.12/_inspect_args.ts +0 -15
- package/src/deps/jsr.io/@std/expect/1.0.12/_matchers.ts +0 -1028
- package/src/deps/jsr.io/@std/expect/1.0.12/_mock_util.ts +0 -22
- package/src/deps/jsr.io/@std/expect/1.0.12/_serializer.ts +0 -15
- package/src/deps/jsr.io/@std/expect/1.0.12/_types.ts +0 -923
- package/src/deps/jsr.io/@std/expect/1.0.12/_utils.ts +0 -283
- package/src/deps/jsr.io/@std/expect/1.0.12/expect.ts +0 -620
- package/src/deps/jsr.io/@std/expect/1.0.12/fn.ts +0 -91
- package/src/deps/jsr.io/@std/expect/1.0.12/mod.ts +0 -89
- package/src/deps/jsr.io/@std/internal/1.0.5/assertion_state.ts +0 -214
- package/src/deps/jsr.io/@std/internal/1.0.5/build_message.ts +0 -134
- package/src/deps/jsr.io/@std/internal/1.0.5/diff.ts +0 -317
- package/src/deps/jsr.io/@std/internal/1.0.5/diff_str.ts +0 -204
- package/src/deps/jsr.io/@std/internal/1.0.5/format.ts +0 -39
- package/src/deps/jsr.io/@std/internal/1.0.5/styles.ts +0 -233
- package/src/deps/jsr.io/@std/internal/1.0.5/types.ts +0 -18
- package/src/deps/jsr.io/@std/testing/1.0.9/_mock_utils.ts +0 -43
- package/src/deps/jsr.io/@std/testing/1.0.9/_test_suite.ts +0 -448
- package/src/deps/jsr.io/@std/testing/1.0.9/bdd.ts +0 -1288
- package/src/deps/jsr.io/@std/testing/1.0.9/mock.ts +0 -1807
- package/src/mod.ts +0 -7
- package/src/src/assets.ts +0 -9
- package/src/src/ast/_index.ts +0 -54
- package/src/src/ast/common.ts +0 -1
- package/src/src/ast/index.ts +0 -1
- package/src/src/ast/node.ts +0 -10
- package/src/src/ast/nodes/argument.test.ts +0 -43
- package/src/src/ast/nodes/argument.ts +0 -40
- package/src/src/ast/nodes/array-type.test.ts +0 -34
- package/src/src/ast/nodes/array-type.ts +0 -49
- package/src/src/ast/nodes/arrow-function.test.ts +0 -79
- package/src/src/ast/nodes/arrow-function.ts +0 -91
- package/src/src/ast/nodes/call.ts +0 -55
- package/src/src/ast/nodes/class.test.ts +0 -185
- package/src/src/ast/nodes/class.ts +0 -133
- package/src/src/ast/nodes/constructor-parameter.test.ts +0 -122
- package/src/src/ast/nodes/constructor-parameter.ts +0 -70
- package/src/src/ast/nodes/constructor.test.ts +0 -131
- package/src/src/ast/nodes/constructor.ts +0 -77
- package/src/src/ast/nodes/decorator.test.ts +0 -59
- package/src/src/ast/nodes/decorator.ts +0 -76
- package/src/src/ast/nodes/doc-tag.test.ts +0 -40
- package/src/src/ast/nodes/doc-tag.ts +0 -291
- package/src/src/ast/nodes/doc.test.ts +0 -40
- package/src/src/ast/nodes/doc.ts +0 -102
- package/src/src/ast/nodes/enum-value.test.ts +0 -66
- package/src/src/ast/nodes/enum-value.ts +0 -72
- package/src/src/ast/nodes/enum.test.ts +0 -85
- package/src/src/ast/nodes/enum.ts +0 -77
- package/src/src/ast/nodes/export.test.ts +0 -29
- package/src/src/ast/nodes/export.ts +0 -54
- package/src/src/ast/nodes/function-type.test.ts +0 -61
- package/src/src/ast/nodes/function-type.ts +0 -60
- package/src/src/ast/nodes/function.test.ts +0 -135
- package/src/src/ast/nodes/function.ts +0 -107
- package/src/src/ast/nodes/generic-parameter.test.ts +0 -86
- package/src/src/ast/nodes/generic-parameter.ts +0 -71
- package/src/src/ast/nodes/indexer.test.ts +0 -42
- package/src/src/ast/nodes/indexer.ts +0 -60
- package/src/src/ast/nodes/interface.test.ts +0 -142
- package/src/src/ast/nodes/interface.ts +0 -117
- package/src/src/ast/nodes/intersection-type.test.ts +0 -52
- package/src/src/ast/nodes/intersection-type.ts +0 -67
- package/src/src/ast/nodes/lookup-type.ts +0 -53
- package/src/src/ast/nodes/method.test.ts +0 -185
- package/src/src/ast/nodes/method.ts +0 -138
- package/src/src/ast/nodes/object-type.test.ts +0 -40
- package/src/src/ast/nodes/object-type.ts +0 -52
- package/src/src/ast/nodes/object.test.ts +0 -40
- package/src/src/ast/nodes/object.ts +0 -48
- package/src/src/ast/nodes/parameter.test.ts +0 -88
- package/src/src/ast/nodes/parameter.ts +0 -85
- package/src/src/ast/nodes/property-accessor.test.ts +0 -132
- package/src/src/ast/nodes/property-accessor.ts +0 -173
- package/src/src/ast/nodes/property.test.ts +0 -113
- package/src/src/ast/nodes/property.ts +0 -192
- package/src/src/ast/nodes/reference.test.ts +0 -42
- package/src/src/ast/nodes/reference.ts +0 -194
- package/src/src/ast/nodes/string.test.ts +0 -35
- package/src/src/ast/nodes/string.ts +0 -49
- package/src/src/ast/nodes/tuple.test.ts +0 -45
- package/src/src/ast/nodes/tuple.ts +0 -53
- package/src/src/ast/nodes/type-alias.test.ts +0 -35
- package/src/src/ast/nodes/type-alias.ts +0 -75
- package/src/src/ast/nodes/typeof.ts +0 -42
- package/src/src/ast/nodes/types.ts +0 -40
- package/src/src/ast/nodes/union-type.test.ts +0 -50
- package/src/src/ast/nodes/union-type.ts +0 -62
- package/src/src/ast/nodes/variable.test.ts +0 -49
- package/src/src/ast/nodes/variable.ts +0 -73
- package/src/src/ast/references/angular.ts +0 -24
- package/src/src/ast/references/easy-network-stub.ts +0 -21
- package/src/src/ast/references/index.ts +0 -5
- package/src/src/ast/references/k6.ts +0 -8
- package/src/src/ast/references/rxjs.ts +0 -7
- package/src/src/ast/references/typescript.ts +0 -35
- package/src/src/ast/utils/get-type-script-builder-options.ts +0 -19
- package/src/src/ast/utils/to-ts-node.ts +0 -27
- package/src/src/ast/utils/write-ts-generic-parameters.ts +0 -25
- package/src/src/ast/utils/write-ts-members.ts +0 -28
- package/src/src/ast/utils/write-ts-nodes.ts +0 -35
- package/src/src/ast/utils/write-ts-parameters.ts +0 -25
- package/src/src/common-results.ts +0 -26
- package/src/src/config.ts +0 -89
- package/src/src/file-builder.ts +0 -136
- package/src/src/generators/file-generator.ts +0 -15
- package/src/src/generators/index.ts +0 -6
- package/src/src/generators/models/index.ts +0 -3
- package/src/src/generators/models/model-generator.ts +0 -469
- package/src/src/generators/models/models-generator.ts +0 -108
- package/src/src/generators/models/models.ts +0 -112
- package/src/src/generators/services/angular-services/angular-service-generator.ts +0 -404
- package/src/src/generators/services/angular-services/angular-services-generator.ts +0 -295
- package/src/src/generators/services/angular-services/index.ts +0 -3
- package/src/src/generators/services/angular-services/models.ts +0 -270
- package/src/src/generators/services/angular-services/refs.ts +0 -54
- package/src/src/generators/services/easy-network-stub/easy-network-stub-generator.ts +0 -242
- package/src/src/generators/services/easy-network-stub/easy-network-stubs-generator.ts +0 -211
- package/src/src/generators/services/easy-network-stub/index.ts +0 -3
- package/src/src/generators/services/easy-network-stub/models.ts +0 -124
- package/src/src/generators/services/easy-network-stub/refs.ts +0 -45
- package/src/src/generators/services/fetch-clients/fetch-client-generator.ts +0 -267
- package/src/src/generators/services/fetch-clients/fetch-clients-generator.ts +0 -163
- package/src/src/generators/services/fetch-clients/index.ts +0 -3
- package/src/src/generators/services/fetch-clients/models.ts +0 -130
- package/src/src/generators/services/fetch-clients/refs.ts +0 -21
- package/src/src/generators/services/k6-clients/index.ts +0 -3
- package/src/src/generators/services/k6-clients/k6-client-generator.ts +0 -409
- package/src/src/generators/services/k6-clients/k6-clients-generator.ts +0 -165
- package/src/src/generators/services/k6-clients/models.ts +0 -241
- package/src/src/generators/services/k6-clients/refs.ts +0 -15
- package/src/src/import-collection.test.ts +0 -78
- package/src/src/import-collection.ts +0 -236
- package/src/src/utils.ts +0 -72
- package/src/tests/openapi-models.test.ts +0 -64
- package/test_runner.js +0 -239
|
@@ -1,259 +1,259 @@
|
|
|
1
|
-
import type { EasyNetworkStub } from 'easy-network-stub';
|
|
2
|
-
|
|
3
|
-
import type { ErrorResponse, HttpMethod, RouteResponseCallback } from 'easy-network-stub';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Options for the `EasyNetworkStubWrapper`.
|
|
7
|
-
*/
|
|
8
|
-
export type EasyNetworkStubWrapperOptions = {
|
|
9
|
-
/**
|
|
10
|
-
* Delay in milliseconds before responding.
|
|
11
|
-
* @default 0
|
|
12
|
-
*/
|
|
13
|
-
delay: number;
|
|
14
|
-
/**
|
|
15
|
-
* Whether to log requests to the console.
|
|
16
|
-
* @default false
|
|
17
|
-
*/
|
|
18
|
-
logRequests: boolean;
|
|
19
|
-
/**
|
|
20
|
-
* Whether to log responses to the console.
|
|
21
|
-
* @default false
|
|
22
|
-
*/
|
|
23
|
-
logResponses: boolean;
|
|
24
|
-
/**
|
|
25
|
-
* Whether to remember requests. Remebered requests can be accessed via the `requests` property.
|
|
26
|
-
* @default false
|
|
27
|
-
*/
|
|
28
|
-
rememberRequests: boolean;
|
|
29
|
-
/**
|
|
30
|
-
* Function to call when a response is sent.
|
|
31
|
-
* @param response The response that was sent.
|
|
32
|
-
* @default undefined
|
|
33
|
-
*/
|
|
34
|
-
responseCallback?: (response: unknown) => void;
|
|
35
|
-
/**
|
|
36
|
-
* A prefix to add to the URL in log messages.
|
|
37
|
-
* @default /api/
|
|
38
|
-
*/
|
|
39
|
-
logUrlPrefix: string;
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* Represents a request intercepted by the `EasyNetworkStubWrapper`.
|
|
44
|
-
*/
|
|
45
|
-
export type StubRequestItem = {
|
|
46
|
-
/**
|
|
47
|
-
* The HTTP method of the request.
|
|
48
|
-
*/
|
|
49
|
-
method: HttpMethod;
|
|
50
|
-
/**
|
|
51
|
-
* The route of the request.
|
|
52
|
-
*/
|
|
53
|
-
route: string;
|
|
54
|
-
/**
|
|
55
|
-
* The request information provided by `easy-network-stub`.
|
|
56
|
-
*/
|
|
57
|
-
request: StubRequestInfo;
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* Represents the request information provided by `easy-network-stub`.
|
|
62
|
-
*/
|
|
63
|
-
export type StubRequestInfo<TRoute extends string = string, TBody = unknown> = Parameters<
|
|
64
|
-
RouteResponseCallback<TRoute, TBody>
|
|
65
|
-
>[0];
|
|
66
|
-
|
|
67
|
-
/**
|
|
68
|
-
* A strict version of `RouteResponseCallback` that allows for a responder to be passed as the first argument.
|
|
69
|
-
*/
|
|
70
|
-
export type StrictRouteResponseCallback<T, P extends string, R> = (
|
|
71
|
-
respondWith: R,
|
|
72
|
-
...args: Parameters<RouteResponseCallback<P, T>>
|
|
73
|
-
) => ErrorResponse<any> | Promise<ErrorResponse<any>>;
|
|
74
|
-
|
|
75
|
-
type _UnionToIntersection<U> = (U extends any ? (x: U) => void : never) extends (x: infer I) => void ? I : never;
|
|
76
|
-
type __StubResponder<T extends Record<number, unknown>, S> = S extends number
|
|
77
|
-
? [T[S]] extends [never] ? (statusCode: S) => ErrorResponse<T[S]>
|
|
78
|
-
: (statusCode: S, content: T[S]) => ErrorResponse<T[S]>
|
|
79
|
-
: never;
|
|
80
|
-
type _StubResponder<T extends Record<number, unknown>> = _UnionToIntersection<__StubResponder<T, keyof T>>;
|
|
81
|
-
const untypedResponder = (statusCode: number, content?: unknown) => ({ statusCode, content });
|
|
82
|
-
|
|
83
|
-
/**
|
|
84
|
-
* Gets the responder function typed to a specific set of status codes.
|
|
85
|
-
* @returns The responder function.
|
|
86
|
-
*/
|
|
87
|
-
export function getStubResponder<T extends Record<number, unknown>>(): _StubResponder<T> {
|
|
88
|
-
return untypedResponder as _StubResponder<T>;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* Wrapper for `EasyNetworkStub` that adds additional functionality.
|
|
93
|
-
*/
|
|
94
|
-
export class EasyNetworkStubWrapper {
|
|
95
|
-
private _requests: StubRequestItem[] = [];
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* The options for the wrapper.
|
|
99
|
-
*/
|
|
100
|
-
public readonly options: Readonly<EasyNetworkStubWrapperOptions>;
|
|
101
|
-
|
|
102
|
-
/**
|
|
103
|
-
* The requests that have been intercepted by the wrapper.
|
|
104
|
-
*/
|
|
105
|
-
public get requests(): ReadonlyArray<StubRequestItem> {
|
|
106
|
-
return this._requests;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
constructor(
|
|
110
|
-
public readonly wrappedStub: EasyNetworkStub,
|
|
111
|
-
options?: Partial<EasyNetworkStubWrapperOptions>,
|
|
112
|
-
) {
|
|
113
|
-
this.options = {
|
|
114
|
-
delay: options?.delay ?? 0,
|
|
115
|
-
logRequests: options?.logRequests ?? false,
|
|
116
|
-
logResponses: options?.logResponses ?? false,
|
|
117
|
-
rememberRequests: options?.rememberRequests ?? false,
|
|
118
|
-
responseCallback: options?.responseCallback,
|
|
119
|
-
logUrlPrefix: options?.logUrlPrefix ?? '/api/',
|
|
120
|
-
};
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
/**
|
|
124
|
-
* Add a single api stub to your intercepted routes.
|
|
125
|
-
* @param method The http method that should be stubbed
|
|
126
|
-
* @param route The route that should be stubbed. Supports parameters in the form of {name:type}.
|
|
127
|
-
* @param response The callback in which you can process the request and reply with the stub. When a Promise is returned, the stub response will be delayed until it is resolved.
|
|
128
|
-
*/
|
|
129
|
-
public stub<Route extends string>(
|
|
130
|
-
method: HttpMethod,
|
|
131
|
-
route: Route,
|
|
132
|
-
response: RouteResponseCallback<Route, unknown>,
|
|
133
|
-
): void {
|
|
134
|
-
this.wrappedStub.stub<Route>(method, route, async (request) => {
|
|
135
|
-
if (this.options.delay > 0) await sleep(this.options.delay);
|
|
136
|
-
return await this.runRequest(method, route, response, request);
|
|
137
|
-
});
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
/**
|
|
141
|
-
* The stub2 method provides a way to set the type of the body that is sent.
|
|
142
|
-
* Due to restrictions in TypeScript (https://github.com/microsoft/TypeScript/issues/10571, https://github.com/Microsoft/TypeScript/pull/26349),
|
|
143
|
-
* We have to hacke a bit here. Calling stub2<T>() will return the stub method with a body of type T.
|
|
144
|
-
*
|
|
145
|
-
* Usage:
|
|
146
|
-
* ```
|
|
147
|
-
* .stub2<MyRequest>()('GET', '/api/test', ({ body }) => {
|
|
148
|
-
* // body is of type MyRequest
|
|
149
|
-
* });
|
|
150
|
-
* ```
|
|
151
|
-
* @returns The stub method with a body of type T.
|
|
152
|
-
*/
|
|
153
|
-
public stub2<T>(): <Route extends string>(
|
|
154
|
-
method: HttpMethod,
|
|
155
|
-
route: Route,
|
|
156
|
-
response: RouteResponseCallback<Route, T>,
|
|
157
|
-
) => void {
|
|
158
|
-
return <Route extends string>(method: HttpMethod, route: Route, response: RouteResponseCallback<Route, T>) => {
|
|
159
|
-
this.wrappedStub.stub2<T>()<Route>(method, route, async (request) => {
|
|
160
|
-
if (this.options.delay > 0) await sleep(this.options.delay);
|
|
161
|
-
return await this.runRequest(method, route, response, request);
|
|
162
|
-
});
|
|
163
|
-
};
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
/**
|
|
167
|
-
* Reset the stubs and requests.
|
|
168
|
-
*/
|
|
169
|
-
public reset(): void {
|
|
170
|
-
this._requests = [];
|
|
171
|
-
this.wrappedStub['_config'].stubs = [];
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
private async runRequest<Route extends string, T>(
|
|
175
|
-
method: HttpMethod,
|
|
176
|
-
route: Route,
|
|
177
|
-
response: RouteResponseCallback<Route, T>,
|
|
178
|
-
request: StubRequestInfo<Route, T>,
|
|
179
|
-
): Promise<unknown> {
|
|
180
|
-
if (this.options.rememberRequests) {
|
|
181
|
-
this._requests.push({ method, route, request });
|
|
182
|
-
}
|
|
183
|
-
this.log('request', method, route, request, '#7FFFFF');
|
|
184
|
-
try {
|
|
185
|
-
const r = await response(request);
|
|
186
|
-
this.options.responseCallback?.(r);
|
|
187
|
-
this.log('response', method, route, r, '#7FFF8E');
|
|
188
|
-
return r;
|
|
189
|
-
} catch (error: unknown) {
|
|
190
|
-
this.options.responseCallback?.(error);
|
|
191
|
-
if (isHttpResponse(error) && error.statusCode >= 200 && error.statusCode < 300) {
|
|
192
|
-
this.log('response', method, route, error.content, '#7FFF8E');
|
|
193
|
-
throw error;
|
|
194
|
-
} else {
|
|
195
|
-
const isError = isHttpResponse(error) && error.statusCode >= 400 && error.statusCode < 600;
|
|
196
|
-
this.log('response', method, route, error, isError ? '#FF7F7F' : '7F7F7F');
|
|
197
|
-
throw error;
|
|
198
|
-
}
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
private log(type: 'request' | 'response', method: HttpMethod, route: string, data: unknown, color: string) {
|
|
203
|
-
if (type === 'request' && !this.options.logRequests) return;
|
|
204
|
-
if (type === 'response' && !this.options.logResponses) return;
|
|
205
|
-
const typeDisplay = type === 'request' ? ' [req]' : '[resp]';
|
|
206
|
-
const strippedRoute = route.match(/[^?]*(?=\?)?/)?.[0];
|
|
207
|
-
console.log(`%c${typeDisplay} ${method}: ${this.options.logUrlPrefix}${strippedRoute}`, `color:${color};`, data);
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
/**
|
|
212
|
-
* Base class for generated easy network stubs.
|
|
213
|
-
*/
|
|
214
|
-
export class EasyNetworkStubBase {
|
|
215
|
-
protected readonly stubWrapper: EasyNetworkStubWrapper;
|
|
216
|
-
protected readonly ownsStubWrapper: boolean;
|
|
217
|
-
|
|
218
|
-
constructor(stub: EasyNetworkStub | EasyNetworkStubWrapper, options?: EasyNetworkStubWrapperOptions) {
|
|
219
|
-
this.stubWrapper = stub instanceof EasyNetworkStubWrapper ? stub : new EasyNetworkStubWrapper(stub, options);
|
|
220
|
-
this.ownsStubWrapper = !(stub instanceof EasyNetworkStubWrapper);
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
public reset() {
|
|
224
|
-
if (this.ownsStubWrapper) {
|
|
225
|
-
this.stubWrapper.reset();
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
export type EasyNetworkStubGroup<Group, GroupContainer> = Group & {
|
|
231
|
-
(stubActions: (stubs: Group) => void): GroupContainer;
|
|
232
|
-
};
|
|
233
|
-
|
|
234
|
-
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
235
|
-
declare interface GroupType<T> extends Function {
|
|
236
|
-
new (stubWrapper: EasyNetworkStubWrapper): T;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
export function createEasyNetworkStubGroup<GroupContainer, Group>(
|
|
240
|
-
container: GroupContainer,
|
|
241
|
-
stubWrapper: EasyNetworkStubWrapper,
|
|
242
|
-
groupType: GroupType<Group>,
|
|
243
|
-
): EasyNetworkStubGroup<Group, GroupContainer> {
|
|
244
|
-
const group = new groupType(stubWrapper);
|
|
245
|
-
const groupFn = (stubActions: (stubs: Group) => void) => {
|
|
246
|
-
stubActions(group);
|
|
247
|
-
return container;
|
|
248
|
-
};
|
|
249
|
-
Object.setPrototypeOf(groupFn, groupType.prototype);
|
|
250
|
-
return Object.assign(groupFn, group);
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
function sleep(ms: number): Promise<void> {
|
|
254
|
-
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
function isHttpResponse(value: unknown): value is ErrorResponse<unknown> {
|
|
258
|
-
return typeof value === 'object' && value !== null && 'statusCode' in value;
|
|
259
|
-
}
|
|
1
|
+
import type { EasyNetworkStub } from 'easy-network-stub';
|
|
2
|
+
|
|
3
|
+
import type { ErrorResponse, HttpMethod, RouteResponseCallback } from 'easy-network-stub';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Options for the `EasyNetworkStubWrapper`.
|
|
7
|
+
*/
|
|
8
|
+
export type EasyNetworkStubWrapperOptions = {
|
|
9
|
+
/**
|
|
10
|
+
* Delay in milliseconds before responding.
|
|
11
|
+
* @default 0
|
|
12
|
+
*/
|
|
13
|
+
delay: number;
|
|
14
|
+
/**
|
|
15
|
+
* Whether to log requests to the console.
|
|
16
|
+
* @default false
|
|
17
|
+
*/
|
|
18
|
+
logRequests: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Whether to log responses to the console.
|
|
21
|
+
* @default false
|
|
22
|
+
*/
|
|
23
|
+
logResponses: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Whether to remember requests. Remebered requests can be accessed via the `requests` property.
|
|
26
|
+
* @default false
|
|
27
|
+
*/
|
|
28
|
+
rememberRequests: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Function to call when a response is sent.
|
|
31
|
+
* @param response The response that was sent.
|
|
32
|
+
* @default undefined
|
|
33
|
+
*/
|
|
34
|
+
responseCallback?: (response: unknown) => void;
|
|
35
|
+
/**
|
|
36
|
+
* A prefix to add to the URL in log messages.
|
|
37
|
+
* @default /api/
|
|
38
|
+
*/
|
|
39
|
+
logUrlPrefix: string;
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* Represents a request intercepted by the `EasyNetworkStubWrapper`.
|
|
44
|
+
*/
|
|
45
|
+
export type StubRequestItem = {
|
|
46
|
+
/**
|
|
47
|
+
* The HTTP method of the request.
|
|
48
|
+
*/
|
|
49
|
+
method: HttpMethod;
|
|
50
|
+
/**
|
|
51
|
+
* The route of the request.
|
|
52
|
+
*/
|
|
53
|
+
route: string;
|
|
54
|
+
/**
|
|
55
|
+
* The request information provided by `easy-network-stub`.
|
|
56
|
+
*/
|
|
57
|
+
request: StubRequestInfo;
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Represents the request information provided by `easy-network-stub`.
|
|
62
|
+
*/
|
|
63
|
+
export type StubRequestInfo<TRoute extends string = string, TBody = unknown> = Parameters<
|
|
64
|
+
RouteResponseCallback<TRoute, TBody>
|
|
65
|
+
>[0];
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* A strict version of `RouteResponseCallback` that allows for a responder to be passed as the first argument.
|
|
69
|
+
*/
|
|
70
|
+
export type StrictRouteResponseCallback<T, P extends string, R> = (
|
|
71
|
+
respondWith: R,
|
|
72
|
+
...args: Parameters<RouteResponseCallback<P, T>>
|
|
73
|
+
) => ErrorResponse<any> | Promise<ErrorResponse<any>>;
|
|
74
|
+
|
|
75
|
+
type _UnionToIntersection<U> = (U extends any ? (x: U) => void : never) extends (x: infer I) => void ? I : never;
|
|
76
|
+
type __StubResponder<T extends Record<number, unknown>, S> = S extends number
|
|
77
|
+
? [T[S]] extends [never] ? (statusCode: S) => ErrorResponse<T[S]>
|
|
78
|
+
: (statusCode: S, content: T[S]) => ErrorResponse<T[S]>
|
|
79
|
+
: never;
|
|
80
|
+
type _StubResponder<T extends Record<number, unknown>> = _UnionToIntersection<__StubResponder<T, keyof T>>;
|
|
81
|
+
const untypedResponder = (statusCode: number, content?: unknown) => ({ statusCode, content });
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Gets the responder function typed to a specific set of status codes.
|
|
85
|
+
* @returns The responder function.
|
|
86
|
+
*/
|
|
87
|
+
export function getStubResponder<T extends Record<number, unknown>>(): _StubResponder<T> {
|
|
88
|
+
return untypedResponder as _StubResponder<T>;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Wrapper for `EasyNetworkStub` that adds additional functionality.
|
|
93
|
+
*/
|
|
94
|
+
export class EasyNetworkStubWrapper {
|
|
95
|
+
private _requests: StubRequestItem[] = [];
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* The options for the wrapper.
|
|
99
|
+
*/
|
|
100
|
+
public readonly options: Readonly<EasyNetworkStubWrapperOptions>;
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* The requests that have been intercepted by the wrapper.
|
|
104
|
+
*/
|
|
105
|
+
public get requests(): ReadonlyArray<StubRequestItem> {
|
|
106
|
+
return this._requests;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
constructor(
|
|
110
|
+
public readonly wrappedStub: EasyNetworkStub,
|
|
111
|
+
options?: Partial<EasyNetworkStubWrapperOptions>,
|
|
112
|
+
) {
|
|
113
|
+
this.options = {
|
|
114
|
+
delay: options?.delay ?? 0,
|
|
115
|
+
logRequests: options?.logRequests ?? false,
|
|
116
|
+
logResponses: options?.logResponses ?? false,
|
|
117
|
+
rememberRequests: options?.rememberRequests ?? false,
|
|
118
|
+
responseCallback: options?.responseCallback,
|
|
119
|
+
logUrlPrefix: options?.logUrlPrefix ?? '/api/',
|
|
120
|
+
};
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* Add a single api stub to your intercepted routes.
|
|
125
|
+
* @param method The http method that should be stubbed
|
|
126
|
+
* @param route The route that should be stubbed. Supports parameters in the form of {name:type}.
|
|
127
|
+
* @param response The callback in which you can process the request and reply with the stub. When a Promise is returned, the stub response will be delayed until it is resolved.
|
|
128
|
+
*/
|
|
129
|
+
public stub<Route extends string>(
|
|
130
|
+
method: HttpMethod,
|
|
131
|
+
route: Route,
|
|
132
|
+
response: RouteResponseCallback<Route, unknown>,
|
|
133
|
+
): void {
|
|
134
|
+
this.wrappedStub.stub<Route>(method, route, async (request) => {
|
|
135
|
+
if (this.options.delay > 0) await sleep(this.options.delay);
|
|
136
|
+
return await this.runRequest(method, route, response, request);
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* The stub2 method provides a way to set the type of the body that is sent.
|
|
142
|
+
* Due to restrictions in TypeScript (https://github.com/microsoft/TypeScript/issues/10571, https://github.com/Microsoft/TypeScript/pull/26349),
|
|
143
|
+
* We have to hacke a bit here. Calling stub2<T>() will return the stub method with a body of type T.
|
|
144
|
+
*
|
|
145
|
+
* Usage:
|
|
146
|
+
* ```
|
|
147
|
+
* .stub2<MyRequest>()('GET', '/api/test', ({ body }) => {
|
|
148
|
+
* // body is of type MyRequest
|
|
149
|
+
* });
|
|
150
|
+
* ```
|
|
151
|
+
* @returns The stub method with a body of type T.
|
|
152
|
+
*/
|
|
153
|
+
public stub2<T>(): <Route extends string>(
|
|
154
|
+
method: HttpMethod,
|
|
155
|
+
route: Route,
|
|
156
|
+
response: RouteResponseCallback<Route, T>,
|
|
157
|
+
) => void {
|
|
158
|
+
return <Route extends string>(method: HttpMethod, route: Route, response: RouteResponseCallback<Route, T>) => {
|
|
159
|
+
this.wrappedStub.stub2<T>()<Route>(method, route, async (request) => {
|
|
160
|
+
if (this.options.delay > 0) await sleep(this.options.delay);
|
|
161
|
+
return await this.runRequest(method, route, response, request);
|
|
162
|
+
});
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Reset the stubs and requests.
|
|
168
|
+
*/
|
|
169
|
+
public reset(): void {
|
|
170
|
+
this._requests = [];
|
|
171
|
+
this.wrappedStub['_config'].stubs = [];
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
private async runRequest<Route extends string, T>(
|
|
175
|
+
method: HttpMethod,
|
|
176
|
+
route: Route,
|
|
177
|
+
response: RouteResponseCallback<Route, T>,
|
|
178
|
+
request: StubRequestInfo<Route, T>,
|
|
179
|
+
): Promise<unknown> {
|
|
180
|
+
if (this.options.rememberRequests) {
|
|
181
|
+
this._requests.push({ method, route, request });
|
|
182
|
+
}
|
|
183
|
+
this.log('request', method, route, request, '#7FFFFF');
|
|
184
|
+
try {
|
|
185
|
+
const r = await response(request);
|
|
186
|
+
this.options.responseCallback?.(r);
|
|
187
|
+
this.log('response', method, route, r, '#7FFF8E');
|
|
188
|
+
return r;
|
|
189
|
+
} catch (error: unknown) {
|
|
190
|
+
this.options.responseCallback?.(error);
|
|
191
|
+
if (isHttpResponse(error) && error.statusCode >= 200 && error.statusCode < 300) {
|
|
192
|
+
this.log('response', method, route, error.content, '#7FFF8E');
|
|
193
|
+
throw error;
|
|
194
|
+
} else {
|
|
195
|
+
const isError = isHttpResponse(error) && error.statusCode >= 400 && error.statusCode < 600;
|
|
196
|
+
this.log('response', method, route, error, isError ? '#FF7F7F' : '7F7F7F');
|
|
197
|
+
throw error;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
private log(type: 'request' | 'response', method: HttpMethod, route: string, data: unknown, color: string) {
|
|
203
|
+
if (type === 'request' && !this.options.logRequests) return;
|
|
204
|
+
if (type === 'response' && !this.options.logResponses) return;
|
|
205
|
+
const typeDisplay = type === 'request' ? ' [req]' : '[resp]';
|
|
206
|
+
const strippedRoute = route.match(/[^?]*(?=\?)?/)?.[0];
|
|
207
|
+
console.log(`%c${typeDisplay} ${method}: ${this.options.logUrlPrefix}${strippedRoute}`, `color:${color};`, data);
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
/**
|
|
212
|
+
* Base class for generated easy network stubs.
|
|
213
|
+
*/
|
|
214
|
+
export class EasyNetworkStubBase {
|
|
215
|
+
protected readonly stubWrapper: EasyNetworkStubWrapper;
|
|
216
|
+
protected readonly ownsStubWrapper: boolean;
|
|
217
|
+
|
|
218
|
+
constructor(stub: EasyNetworkStub | EasyNetworkStubWrapper, options?: EasyNetworkStubWrapperOptions) {
|
|
219
|
+
this.stubWrapper = stub instanceof EasyNetworkStubWrapper ? stub : new EasyNetworkStubWrapper(stub, options);
|
|
220
|
+
this.ownsStubWrapper = !(stub instanceof EasyNetworkStubWrapper);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
public reset() {
|
|
224
|
+
if (this.ownsStubWrapper) {
|
|
225
|
+
this.stubWrapper.reset();
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export type EasyNetworkStubGroup<Group, GroupContainer> = Group & {
|
|
231
|
+
(stubActions: (stubs: Group) => void): GroupContainer;
|
|
232
|
+
};
|
|
233
|
+
|
|
234
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
235
|
+
declare interface GroupType<T> extends Function {
|
|
236
|
+
new (stubWrapper: EasyNetworkStubWrapper): T;
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
export function createEasyNetworkStubGroup<GroupContainer, Group>(
|
|
240
|
+
container: GroupContainer,
|
|
241
|
+
stubWrapper: EasyNetworkStubWrapper,
|
|
242
|
+
groupType: GroupType<Group>,
|
|
243
|
+
): EasyNetworkStubGroup<Group, GroupContainer> {
|
|
244
|
+
const group = new groupType(stubWrapper);
|
|
245
|
+
const groupFn = (stubActions: (stubs: Group) => void) => {
|
|
246
|
+
stubActions(group);
|
|
247
|
+
return container;
|
|
248
|
+
};
|
|
249
|
+
Object.setPrototypeOf(groupFn, groupType.prototype);
|
|
250
|
+
return Object.assign(groupFn, group);
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
function sleep(ms: number): Promise<void> {
|
|
254
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
function isHttpResponse(value: unknown): value is ErrorResponse<unknown> {
|
|
258
|
+
return typeof value === 'object' && value !== null && 'statusCode' in value;
|
|
259
|
+
}
|
package/esm/src/file-builder.js
CHANGED
|
@@ -69,7 +69,7 @@ export class TypeScriptFileBuilder extends SourceBuilder {
|
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
71
|
appendModelUsage(type, options) {
|
|
72
|
-
this.append(type.component);
|
|
72
|
+
this.append((options === null || options === void 0 ? void 0 : options.type) === 'js-doc' ? type.component.replace(/\/\*\*.*\*\/\s*/gs, '') : type.component);
|
|
73
73
|
for (const i of type.imports) {
|
|
74
74
|
this.addImport(i.name, i.modulePath, { ...i, ...options });
|
|
75
75
|
}
|
|
@@ -22,6 +22,7 @@ export declare class DefaultTypeScriptAngularServiceGenerator extends TypeScript
|
|
|
22
22
|
protected getEndpointParamsType(ctx: Context, endpoint: ApiEndpoint): ts.TypeAlias<Builder>;
|
|
23
23
|
protected getClass(ctx: Context): ts.Class<Builder>;
|
|
24
24
|
protected getEndpointMethod(ctx: Context, endpoint: ApiEndpoint): ts.Method<Builder>;
|
|
25
|
+
protected getEndpointRequestContentType(ctx: Context, endpoint: ApiEndpoint): string;
|
|
25
26
|
protected getEndpointSuccessResponseType(ctx: Context, endpoint: ApiEndpoint): string;
|
|
26
27
|
protected getEndpointSuccessResponse(_ctx: Context, endpoint: ApiEndpoint): ApiResponse | undefined;
|
|
27
28
|
protected getServiceClassName(ctx: Context): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"angular-service-generator.d.ts","sourceRoot":"","sources":["../../../../../src/src/generators/services/angular-services/angular-service-generator.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,gBAAgB,EAGrB,KAAK,YAAY,EAGlB,MAAM,aAAa,CAAC;AAErB,OAAO,EAAE,EAAE,EAAE,MAAM,uBAAuB,CAAC;AAC3C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AACzE,OAAO,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,KAAK,EAAE,wCAAwC,EAAE,uCAAuC,EAAE,MAAM,aAAa,CAAC;AAErH,KAAK,OAAO,GAAG,wCAAwC,CAAC;AACxD,KAAK,MAAM,GAAG,uCAAuC,CAAC;AACtD,KAAK,OAAO,GAAG,qBAAqB,CAAC;AAErC,MAAM,WAAW,iCAAiC,CAAC,OAAO,SAAS,MAAM,GAAG,MAAM;IAChF,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;CAC/C;AAED,qBAAa,wCAAyC,SAAQ,uBAAuB,CAAC,OAAO,EAAE,MAAM,CACnG,YAAW,iCAAiC;IACrC,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,YAAY,CAAC,MAAM,CAAC;IAqBnD,SAAS,CAAC,sBAAsB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,CAAC,MAAM,EAAE,sBAAsB,CAAC;IAetF,SAAS,CAAC,2BAA2B,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,gBAAgB,CAAC,OAAO,CAAC;IAmErG,SAAS,CAAC,sBAAsB,CAC9B,GAAG,EAAE,OAAO,EACZ,QAAQ,EAAE,WAAW,GACpB,MAAM,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;QAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,CAAA;KAAE,CAAC;IAwBtE,SAAS,CAAC,qBAAqB,CAAC,GAAG,EAAE,OAAO,GAAG,gBAAgB,CAAC,OAAO,CAAC;IAWxE,SAAS,CAAC,qBAAqB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,EAAE,CAAC,SAAS,CAAC,OAAO,CAAC;IAkC3F,SAAS,CAAC,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;IAgCnD,SAAS,CAAC,iBAAiB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"angular-service-generator.d.ts","sourceRoot":"","sources":["../../../../../src/src/generators/services/angular-services/angular-service-generator.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,gBAAgB,EAGrB,KAAK,YAAY,EAGlB,MAAM,aAAa,CAAC;AAErB,OAAO,EAAE,EAAE,EAAE,MAAM,uBAAuB,CAAC;AAC3C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AACzE,OAAO,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,KAAK,EAAE,wCAAwC,EAAE,uCAAuC,EAAE,MAAM,aAAa,CAAC;AAErH,KAAK,OAAO,GAAG,wCAAwC,CAAC;AACxD,KAAK,MAAM,GAAG,uCAAuC,CAAC;AACtD,KAAK,OAAO,GAAG,qBAAqB,CAAC;AAErC,MAAM,WAAW,iCAAiC,CAAC,OAAO,SAAS,MAAM,GAAG,MAAM;IAChF,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;CAC/C;AAED,qBAAa,wCAAyC,SAAQ,uBAAuB,CAAC,OAAO,EAAE,MAAM,CACnG,YAAW,iCAAiC;IACrC,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,YAAY,CAAC,MAAM,CAAC;IAqBnD,SAAS,CAAC,sBAAsB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,CAAC,MAAM,EAAE,sBAAsB,CAAC;IAetF,SAAS,CAAC,2BAA2B,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,gBAAgB,CAAC,OAAO,CAAC;IAmErG,SAAS,CAAC,sBAAsB,CAC9B,GAAG,EAAE,OAAO,EACZ,QAAQ,EAAE,WAAW,GACpB,MAAM,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;QAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,CAAA;KAAE,CAAC;IAwBtE,SAAS,CAAC,qBAAqB,CAAC,GAAG,EAAE,OAAO,GAAG,gBAAgB,CAAC,OAAO,CAAC;IAWxE,SAAS,CAAC,qBAAqB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,EAAE,CAAC,SAAS,CAAC,OAAO,CAAC;IAkC3F,SAAS,CAAC,QAAQ,CAAC,GAAG,EAAE,OAAO,GAAG,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;IAgCnD,SAAS,CAAC,iBAAiB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC;IA+FpF,SAAS,CAAC,6BAA6B,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAIpF,SAAS,CAAC,8BAA8B,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAarF,SAAS,CAAC,0BAA0B,CAAC,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,WAAW,GAAG,SAAS;IAOnG,SAAS,CAAC,mBAAmB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM;IAInD,SAAS,CAAC,oBAAoB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAI3E,SAAS,CAAC,yBAAyB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAIhF,SAAS,CAAC,2BAA2B,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAIlF,SAAS,CAAC,qBAAqB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,MAAM;IAI5E,SAAS,CAAC,kBAAkB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM;IAQlD,SAAS,CAAC,wBAAwB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM;IAQxD,SAAS,CAAC,iBAAiB,CAAC,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,GAAG,OAAO;IAI1E,SAAS,CAAC,aAAa,CAAC,GAAG,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,GAAG,SAAS,EAAE,QAAQ,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC;IAMnH,OAAO,CAAC,yBAAyB;CAGlC"}
|
|
@@ -211,34 +211,31 @@ export class DefaultTypeScriptAngularServiceGenerator extends TypeScriptFileGene
|
|
|
211
211
|
body: appendValueGroup([
|
|
212
212
|
s `const rb = new ${ctx.refs.requestBuilder()}(this.rootUrl, ${this.getServiceClassName(ctx)}.${this.getEndpointPathPropertyName(ctx, endpoint)}, '${endpoint.method}');`,
|
|
213
213
|
hasParams
|
|
214
|
-
? (b) => {
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
})
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
: null,
|
|
231
|
-
], '\n'), { multiline: true });
|
|
232
|
-
}
|
|
214
|
+
? (b) => b.appendIf(paramsOptional, 'if (params) ').parenthesizeIf(paramsOptional, '{}', appendValueGroup([
|
|
215
|
+
...endpoint.parameters
|
|
216
|
+
.filter((p) => p.target === 'path' || p.target === 'query' || p.target === 'header')
|
|
217
|
+
.map((p) => {
|
|
218
|
+
const options = ts.object({
|
|
219
|
+
members: [
|
|
220
|
+
p.style !== undefined ? ts.property('style', { value: ts.string(p.style) }) : null,
|
|
221
|
+
p.explode !== undefined ? ts.property('explode', { value: ts.toNode(p.explode) }) : null,
|
|
222
|
+
],
|
|
223
|
+
});
|
|
224
|
+
return s `rb.${p.target}(${ts.string(p.name)}, params.${toCasing(p.name, ctx.config.propertyNameCasing)}, ${options});`;
|
|
225
|
+
}),
|
|
226
|
+
endpoint.requestBody
|
|
227
|
+
? s `rb.body(params.body, ${ts.string(this.getEndpointRequestContentType(ctx, endpoint))});`
|
|
228
|
+
: null,
|
|
229
|
+
], '\n'), { multiline: true })
|
|
233
230
|
: null,
|
|
234
231
|
'',
|
|
235
|
-
s `return ${ctx.refs.waitForResponse([responseModelType])}(${s.indent `
|
|
236
|
-
this.http.request(rb.build({${s.indent `
|
|
237
|
-
responseType: ${ts.string(responseType)},
|
|
238
|
-
accept: ${ts.string(accept)},
|
|
239
|
-
context,`}
|
|
240
|
-
})),
|
|
241
|
-
{${s.indent `
|
|
232
|
+
s `return ${ctx.refs.waitForResponse([responseModelType])}(${s.indent `
|
|
233
|
+
this.http.request(rb.build({${s.indent `
|
|
234
|
+
responseType: ${ts.string(responseType)},
|
|
235
|
+
accept: ${ts.string(accept)},
|
|
236
|
+
context,`}
|
|
237
|
+
})),
|
|
238
|
+
{${s.indent `
|
|
242
239
|
errorResponseTypes: ${ts.object({
|
|
243
240
|
members: [
|
|
244
241
|
...Object.entries(this.getEndpointStatusCodes(ctx, endpoint))
|
|
@@ -247,20 +244,24 @@ export class DefaultTypeScriptAngularServiceGenerator extends TypeScriptFileGene
|
|
|
247
244
|
return ts.property(key, { value: ts.string(value.parser) });
|
|
248
245
|
}),
|
|
249
246
|
],
|
|
250
|
-
})}`}
|
|
251
|
-
}`}
|
|
247
|
+
})}`}
|
|
248
|
+
}`}
|
|
252
249
|
)`,
|
|
253
250
|
], '\n'),
|
|
254
251
|
});
|
|
255
252
|
}
|
|
253
|
+
getEndpointRequestContentType(ctx, endpoint) {
|
|
254
|
+
var _a, _b, _c;
|
|
255
|
+
return (_c = (_a = ctx.config.defaultRequestContentType) !== null && _a !== void 0 ? _a : (_b = endpoint === null || endpoint === void 0 ? void 0 : endpoint.requestBody) === null || _b === void 0 ? void 0 : _b.content[0].type) !== null && _c !== void 0 ? _c : 'application/json';
|
|
256
|
+
}
|
|
256
257
|
getEndpointSuccessResponseType(ctx, endpoint) {
|
|
257
258
|
var _a, _b, _c, _d, _e, _f;
|
|
258
259
|
const response = this.getEndpointSuccessResponse(ctx, endpoint);
|
|
259
260
|
if (!response)
|
|
260
261
|
return '*/*';
|
|
261
|
-
if (!ctx.config.
|
|
262
|
+
if (!ctx.config.defaultSuccessResponseContentType)
|
|
262
263
|
return (_b = (_a = response.contentOptions[0]) === null || _a === void 0 ? void 0 : _a.type) !== null && _b !== void 0 ? _b : '*/*';
|
|
263
|
-
return ((_f = (_d = (_c = response.contentOptions.find((x) => x.type === ctx.config.
|
|
264
|
+
return ((_f = (_d = (_c = response.contentOptions.find((x) => x.type === ctx.config.defaultSuccessResponseContentType)) === null || _c === void 0 ? void 0 : _c.type) !== null && _d !== void 0 ? _d : (_e = response.contentOptions[0]) === null || _e === void 0 ? void 0 : _e.type) !== null && _f !== void 0 ? _f : '*/*');
|
|
264
265
|
}
|
|
265
266
|
getEndpointSuccessResponse(_ctx, endpoint) {
|
|
266
267
|
var _a;
|