@goast/kotlin 0.4.6 → 0.4.7-beta2
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 +45 -45
- package/assets/client/okhttp3/ApiClient.kt +250 -250
- package/esm/src/ast/references/spring.d.ts +1 -0
- package/esm/src/ast/references/spring.d.ts.map +1 -1
- package/esm/src/ast/references/spring.js +2 -0
- package/esm/src/generators/services/okhttp3-clients/okhttp3-client-generator.js +26 -26
- package/esm/src/generators/services/spring-controllers/args.d.ts +17 -2
- package/esm/src/generators/services/spring-controllers/args.d.ts.map +1 -1
- package/esm/src/generators/services/spring-controllers/models.d.ts +2 -0
- package/esm/src/generators/services/spring-controllers/models.d.ts.map +1 -1
- package/esm/src/generators/services/spring-controllers/models.js +2 -0
- package/esm/src/generators/services/spring-controllers/spring-controller-generator.d.ts +3 -1
- package/esm/src/generators/services/spring-controllers/spring-controller-generator.d.ts.map +1 -1
- package/esm/src/generators/services/spring-controllers/spring-controller-generator.js +74 -6
- package/package.json +2 -1
- package/script/src/ast/references/spring.d.ts +1 -0
- package/script/src/ast/references/spring.d.ts.map +1 -1
- package/script/src/ast/references/spring.js +3 -1
- package/script/src/generators/services/okhttp3-clients/okhttp3-client-generator.js +26 -26
- package/script/src/generators/services/spring-controllers/args.d.ts +17 -2
- package/script/src/generators/services/spring-controllers/args.d.ts.map +1 -1
- package/script/src/generators/services/spring-controllers/models.d.ts +2 -0
- package/script/src/generators/services/spring-controllers/models.d.ts.map +1 -1
- package/script/src/generators/services/spring-controllers/models.js +2 -0
- package/script/src/generators/services/spring-controllers/spring-controller-generator.d.ts +3 -1
- package/script/src/generators/services/spring-controllers/spring-controller-generator.d.ts.map +1 -1
- package/script/src/generators/services/spring-controllers/spring-controller-generator.js +74 -6
- 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.8/assertion_error.d.ts +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.8/assertion_error.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/assertion_error.js +0 -30
- package/esm/deps/jsr.io/@std/assert/1.0.8/equal.d.ts +0 -17
- package/esm/deps/jsr.io/@std/assert/1.0.8/equal.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/equal.js +0 -183
- package/esm/deps/jsr.io/@std/assert/1.0.8/equals.d.ts +0 -22
- package/esm/deps/jsr.io/@std/assert/1.0.8/equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/equals.js +0 -45
- package/esm/deps/jsr.io/@std/assert/1.0.8/false.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.8/false.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/false.js +0 -22
- package/esm/deps/jsr.io/@std/assert/1.0.8/instance_of.d.ts +0 -23
- package/esm/deps/jsr.io/@std/assert/1.0.8/instance_of.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/instance_of.js +0 -53
- package/esm/deps/jsr.io/@std/assert/1.0.8/is_error.d.ts +0 -25
- package/esm/deps/jsr.io/@std/assert/1.0.8/is_error.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/is_error.js +0 -54
- package/esm/deps/jsr.io/@std/assert/1.0.8/match.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.8/match.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/match.js +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_instance_of.d.ts +0 -20
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_instance_of.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_instance_of.js +0 -29
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_match.d.ts +0 -18
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_match.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_match.js +0 -26
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.d.ts +0 -23
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.js +0 -32
- package/esm/deps/jsr.io/@std/assert/1.0.8/rejects.d.ts +0 -42
- package/esm/deps/jsr.io/@std/assert/1.0.8/rejects.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/rejects.js +0 -53
- package/esm/deps/jsr.io/@std/assert/1.0.8/strict_equals.d.ts +0 -24
- package/esm/deps/jsr.io/@std/assert/1.0.8/strict_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/assert/1.0.8/strict_equals.js +0 -57
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_equals.d.ts +0 -20
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_equals.js +0 -29
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.d.ts +0 -17
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.js +0 -26
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assertions.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assertions.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_assertions.js +0 -13
- package/esm/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.d.ts +0 -46
- package/esm/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.js +0 -160
- package/esm/deps/jsr.io/@std/expect/1.0.8/_build_message.d.ts +0 -6
- package/esm/deps/jsr.io/@std/expect/1.0.8/_build_message.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_build_message.js +0 -29
- package/esm/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.js +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.8/_equal.d.ts +0 -9
- package/esm/deps/jsr.io/@std/expect/1.0.8/_equal.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_equal.js +0 -191
- package/esm/deps/jsr.io/@std/expect/1.0.8/_extend.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.8/_extend.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_extend.js +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.8/_inspect_args.d.ts +0 -3
- package/esm/deps/jsr.io/@std/expect/1.0.8/_inspect_args.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_inspect_args.js +0 -12
- package/esm/deps/jsr.io/@std/expect/1.0.8/_matchers.d.ts +0 -34
- package/esm/deps/jsr.io/@std/expect/1.0.8/_matchers.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_matchers.js +0 -563
- package/esm/deps/jsr.io/@std/expect/1.0.8/_mock_util.d.ts +0 -11
- package/esm/deps/jsr.io/@std/expect/1.0.8/_mock_util.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_mock_util.js +0 -10
- package/esm/deps/jsr.io/@std/expect/1.0.8/_serializer.d.ts +0 -4
- package/esm/deps/jsr.io/@std/expect/1.0.8/_serializer.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_serializer.js +0 -10
- package/esm/deps/jsr.io/@std/expect/1.0.8/_types.d.ts +0 -839
- package/esm/deps/jsr.io/@std/expect/1.0.8/_types.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_types.js +0 -3
- package/esm/deps/jsr.io/@std/expect/1.0.8/_utils.d.ts +0 -9
- package/esm/deps/jsr.io/@std/expect/1.0.8/_utils.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/_utils.js +0 -218
- package/esm/deps/jsr.io/@std/expect/1.0.8/expect.d.ts +0 -60
- package/esm/deps/jsr.io/@std/expect/1.0.8/expect.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/expect/1.0.8/expect.js +0 -523
- 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.5/_mock_utils.d.ts +0 -15
- package/esm/deps/jsr.io/@std/testing/1.0.5/_mock_utils.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.5/_mock_utils.js +0 -35
- package/esm/deps/jsr.io/@std/testing/1.0.5/_test_suite.d.ts +0 -74
- package/esm/deps/jsr.io/@std/testing/1.0.5/_test_suite.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.5/_test_suite.js +0 -350
- package/esm/deps/jsr.io/@std/testing/1.0.5/bdd.d.ts +0 -731
- package/esm/deps/jsr.io/@std/testing/1.0.5/bdd.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.5/bdd.js +0 -581
- package/esm/deps/jsr.io/@std/testing/1.0.5/mock.d.ts +0 -674
- package/esm/deps/jsr.io/@std/testing/1.0.5/mock.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/testing/1.0.5/mock.js +0 -1083
- package/esm/src/ast/nodes/annotation.test.d.ts +0 -2
- package/esm/src/ast/nodes/annotation.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/annotation.test.js +0 -56
- 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 -33
- package/esm/src/ast/nodes/call.test.d.ts +0 -2
- package/esm/src/ast/nodes/call.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/call.test.js +0 -35
- 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 -219
- 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 -139
- 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 -67
- 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 -33
- 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 -115
- 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 -129
- 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 -160
- 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 -49
- package/esm/src/ast/nodes/init-block.test.d.ts +0 -2
- package/esm/src/ast/nodes/init-block.test.d.ts.map +0 -1
- package/esm/src/ast/nodes/init-block.test.js +0 -28
- 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 -121
- 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 -78
- 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 -152
- 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 -206
- 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 -36
- 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 -48
- 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 -99
- 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.8/assertion_error.d.ts +0 -26
- package/script/deps/jsr.io/@std/assert/1.0.8/assertion_error.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/assertion_error.js +0 -34
- package/script/deps/jsr.io/@std/assert/1.0.8/equal.d.ts +0 -17
- package/script/deps/jsr.io/@std/assert/1.0.8/equal.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/equal.js +0 -187
- package/script/deps/jsr.io/@std/assert/1.0.8/equals.d.ts +0 -22
- package/script/deps/jsr.io/@std/assert/1.0.8/equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/equals.js +0 -48
- package/script/deps/jsr.io/@std/assert/1.0.8/false.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.8/false.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/false.js +0 -25
- package/script/deps/jsr.io/@std/assert/1.0.8/instance_of.d.ts +0 -23
- package/script/deps/jsr.io/@std/assert/1.0.8/instance_of.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/instance_of.js +0 -56
- package/script/deps/jsr.io/@std/assert/1.0.8/is_error.d.ts +0 -25
- package/script/deps/jsr.io/@std/assert/1.0.8/is_error.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/is_error.js +0 -57
- package/script/deps/jsr.io/@std/assert/1.0.8/match.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.8/match.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/match.js +0 -29
- package/script/deps/jsr.io/@std/assert/1.0.8/not_instance_of.d.ts +0 -20
- package/script/deps/jsr.io/@std/assert/1.0.8/not_instance_of.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/not_instance_of.js +0 -32
- package/script/deps/jsr.io/@std/assert/1.0.8/not_match.d.ts +0 -18
- package/script/deps/jsr.io/@std/assert/1.0.8/not_match.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/not_match.js +0 -29
- package/script/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.d.ts +0 -23
- package/script/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.js +0 -35
- package/script/deps/jsr.io/@std/assert/1.0.8/rejects.d.ts +0 -42
- package/script/deps/jsr.io/@std/assert/1.0.8/rejects.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/rejects.js +0 -56
- package/script/deps/jsr.io/@std/assert/1.0.8/strict_equals.d.ts +0 -24
- package/script/deps/jsr.io/@std/assert/1.0.8/strict_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/assert/1.0.8/strict_equals.js +0 -60
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_equals.d.ts +0 -20
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_equals.js +0 -32
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.d.ts +0 -17
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.js +0 -29
- package/script/deps/jsr.io/@std/expect/1.0.8/_assertions.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.8/_assertions.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_assertions.js +0 -18
- package/script/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.d.ts +0 -46
- package/script/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.js +0 -182
- package/script/deps/jsr.io/@std/expect/1.0.8/_build_message.d.ts +0 -6
- package/script/deps/jsr.io/@std/expect/1.0.8/_build_message.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_build_message.js +0 -33
- package/script/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.js +0 -15
- package/script/deps/jsr.io/@std/expect/1.0.8/_equal.d.ts +0 -9
- package/script/deps/jsr.io/@std/expect/1.0.8/_equal.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_equal.js +0 -194
- package/script/deps/jsr.io/@std/expect/1.0.8/_extend.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.8/_extend.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_extend.js +0 -15
- package/script/deps/jsr.io/@std/expect/1.0.8/_inspect_args.d.ts +0 -3
- package/script/deps/jsr.io/@std/expect/1.0.8/_inspect_args.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_inspect_args.js +0 -17
- package/script/deps/jsr.io/@std/expect/1.0.8/_matchers.d.ts +0 -34
- package/script/deps/jsr.io/@std/expect/1.0.8/_matchers.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_matchers.js +0 -597
- package/script/deps/jsr.io/@std/expect/1.0.8/_mock_util.d.ts +0 -11
- package/script/deps/jsr.io/@std/expect/1.0.8/_mock_util.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_mock_util.js +0 -14
- package/script/deps/jsr.io/@std/expect/1.0.8/_serializer.d.ts +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.8/_serializer.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_serializer.js +0 -14
- package/script/deps/jsr.io/@std/expect/1.0.8/_types.d.ts +0 -839
- package/script/deps/jsr.io/@std/expect/1.0.8/_types.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_types.js +0 -4
- package/script/deps/jsr.io/@std/expect/1.0.8/_utils.d.ts +0 -9
- package/script/deps/jsr.io/@std/expect/1.0.8/_utils.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/_utils.js +0 -226
- package/script/deps/jsr.io/@std/expect/1.0.8/expect.d.ts +0 -60
- package/script/deps/jsr.io/@std/expect/1.0.8/expect.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/expect/1.0.8/expect.js +0 -527
- 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.5/_mock_utils.d.ts +0 -15
- package/script/deps/jsr.io/@std/testing/1.0.5/_mock_utils.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.5/_mock_utils.js +0 -41
- package/script/deps/jsr.io/@std/testing/1.0.5/_test_suite.d.ts +0 -74
- package/script/deps/jsr.io/@std/testing/1.0.5/_test_suite.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.5/_test_suite.js +0 -355
- package/script/deps/jsr.io/@std/testing/1.0.5/bdd.d.ts +0 -731
- package/script/deps/jsr.io/@std/testing/1.0.5/bdd.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.5/bdd.js +0 -592
- package/script/deps/jsr.io/@std/testing/1.0.5/mock.d.ts +0 -674
- package/script/deps/jsr.io/@std/testing/1.0.5/mock.d.ts.map +0 -1
- package/script/deps/jsr.io/@std/testing/1.0.5/mock.js +0 -1102
- package/script/src/ast/nodes/annotation.test.d.ts +0 -2
- package/script/src/ast/nodes/annotation.test.d.ts.map +0 -1
- package/script/src/ast/nodes/annotation.test.js +0 -58
- 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 -35
- package/script/src/ast/nodes/call.test.d.ts +0 -2
- package/script/src/ast/nodes/call.test.d.ts.map +0 -1
- package/script/src/ast/nodes/call.test.js +0 -37
- 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 -221
- 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 -141
- 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 -69
- 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 -35
- 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 -117
- 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 -131
- 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 -162
- 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 -51
- package/script/src/ast/nodes/init-block.test.d.ts +0 -2
- package/script/src/ast/nodes/init-block.test.d.ts.map +0 -1
- package/script/src/ast/nodes/init-block.test.js +0 -30
- 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 -123
- 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 -80
- 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 -154
- 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 -208
- 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 -38
- 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 -50
- 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 -101
- 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.8/assertion_error.ts +0 -31
- package/src/deps/jsr.io/@std/assert/1.0.8/equal.ts +0 -210
- package/src/deps/jsr.io/@std/assert/1.0.8/equals.ts +0 -52
- package/src/deps/jsr.io/@std/assert/1.0.8/false.ts +0 -26
- package/src/deps/jsr.io/@std/assert/1.0.8/instance_of.ts +0 -64
- package/src/deps/jsr.io/@std/assert/1.0.8/is_error.ts +0 -65
- package/src/deps/jsr.io/@std/assert/1.0.8/match.ts +0 -30
- package/src/deps/jsr.io/@std/assert/1.0.8/not_instance_of.ts +0 -33
- package/src/deps/jsr.io/@std/assert/1.0.8/not_match.ts +0 -30
- package/src/deps/jsr.io/@std/assert/1.0.8/not_strict_equals.ts +0 -42
- package/src/deps/jsr.io/@std/assert/1.0.8/rejects.ts +0 -123
- package/src/deps/jsr.io/@std/assert/1.0.8/strict_equals.ts +0 -67
- package/src/deps/jsr.io/@std/expect/1.0.8/_assert_equals.ts +0 -38
- package/src/deps/jsr.io/@std/expect/1.0.8/_assert_not_equals.ts +0 -35
- package/src/deps/jsr.io/@std/expect/1.0.8/_assertions.ts +0 -18
- package/src/deps/jsr.io/@std/expect/1.0.8/_asymmetric_matchers.ts +0 -193
- package/src/deps/jsr.io/@std/expect/1.0.8/_build_message.ts +0 -51
- package/src/deps/jsr.io/@std/expect/1.0.8/_custom_equality_tester.ts +0 -19
- package/src/deps/jsr.io/@std/expect/1.0.8/_equal.ts +0 -230
- package/src/deps/jsr.io/@std/expect/1.0.8/_extend.ts +0 -16
- package/src/deps/jsr.io/@std/expect/1.0.8/_inspect_args.ts +0 -15
- package/src/deps/jsr.io/@std/expect/1.0.8/_matchers.ts +0 -832
- package/src/deps/jsr.io/@std/expect/1.0.8/_mock_util.ts +0 -22
- package/src/deps/jsr.io/@std/expect/1.0.8/_serializer.ts +0 -15
- package/src/deps/jsr.io/@std/expect/1.0.8/_types.ts +0 -919
- package/src/deps/jsr.io/@std/expect/1.0.8/_utils.ts +0 -283
- package/src/deps/jsr.io/@std/expect/1.0.8/expect.ts +0 -620
- 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.5/_mock_utils.ts +0 -43
- package/src/deps/jsr.io/@std/testing/1.0.5/_test_suite.ts +0 -410
- package/src/deps/jsr.io/@std/testing/1.0.5/bdd.ts +0 -1211
- package/src/deps/jsr.io/@std/testing/1.0.5/mock.ts +0 -1807
- package/src/mod.ts +0 -8
- package/src/src/assets.ts +0 -9
- package/src/src/ast/_index.ts +0 -66
- 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/annotation.test.ts +0 -69
- package/src/src/ast/nodes/annotation.ts +0 -79
- package/src/src/ast/nodes/argument.test.ts +0 -41
- package/src/src/ast/nodes/argument.ts +0 -62
- package/src/src/ast/nodes/call.test.ts +0 -44
- package/src/src/ast/nodes/call.ts +0 -66
- package/src/src/ast/nodes/class.test.ts +0 -274
- package/src/src/ast/nodes/class.ts +0 -178
- package/src/src/ast/nodes/collection-literal.ts +0 -49
- package/src/src/ast/nodes/constructor.test.ts +0 -178
- package/src/src/ast/nodes/constructor.ts +0 -126
- package/src/src/ast/nodes/doc-tag.test.ts +0 -84
- package/src/src/ast/nodes/doc-tag.ts +0 -138
- package/src/src/ast/nodes/doc.test.ts +0 -42
- package/src/src/ast/nodes/doc.ts +0 -111
- package/src/src/ast/nodes/enum-value.test.ts +0 -146
- package/src/src/ast/nodes/enum-value.ts +0 -100
- package/src/src/ast/nodes/enum.test.ts +0 -167
- package/src/src/ast/nodes/enum.ts +0 -163
- package/src/src/ast/nodes/function.test.ts +0 -194
- package/src/src/ast/nodes/function.ts +0 -176
- package/src/src/ast/nodes/generic-parameter.test.ts +0 -60
- package/src/src/ast/nodes/generic-parameter.ts +0 -54
- package/src/src/ast/nodes/init-block.test.ts +0 -36
- package/src/src/ast/nodes/init-block.ts +0 -38
- package/src/src/ast/nodes/interface.test.ts +0 -151
- package/src/src/ast/nodes/interface.ts +0 -133
- package/src/src/ast/nodes/lambda-type.ts +0 -68
- package/src/src/ast/nodes/lambda.ts +0 -68
- package/src/src/ast/nodes/object.test.ts +0 -101
- package/src/src/ast/nodes/object.ts +0 -102
- package/src/src/ast/nodes/parameter.test.ts +0 -191
- package/src/src/ast/nodes/parameter.ts +0 -118
- package/src/src/ast/nodes/property.test.ts +0 -253
- package/src/src/ast/nodes/property.ts +0 -225
- package/src/src/ast/nodes/reference.test.ts +0 -47
- package/src/src/ast/nodes/reference.ts +0 -178
- package/src/src/ast/nodes/string.test.ts +0 -61
- package/src/src/ast/nodes/string.ts +0 -114
- package/src/src/ast/nodes/types.ts +0 -23
- package/src/src/ast/references/index.ts +0 -8
- package/src/src/ast/references/jackson.ts +0 -16
- package/src/src/ast/references/jakarta.ts +0 -10
- package/src/src/ast/references/java.ts +0 -19
- package/src/src/ast/references/kotlin.ts +0 -40
- package/src/src/ast/references/okhttp3.ts +0 -5
- package/src/src/ast/references/reactor.ts +0 -5
- package/src/src/ast/references/spring.ts +0 -58
- package/src/src/ast/references/swagger.ts +0 -23
- package/src/src/ast/utils/get-kotlin-builder-options.ts +0 -19
- package/src/src/ast/utils/to-kt-node.ts +0 -31
- package/src/src/ast/utils/write-kt-annotations.ts +0 -15
- package/src/src/ast/utils/write-kt-arguments.ts +0 -45
- package/src/src/ast/utils/write-kt-enum-values.ts +0 -27
- package/src/src/ast/utils/write-kt-generic-parameters.ts +0 -12
- package/src/src/ast/utils/write-kt-members.ts +0 -25
- package/src/src/ast/utils/write-kt-node.ts +0 -37
- package/src/src/ast/utils/write-kt-parameters.ts +0 -25
- package/src/src/common-results.ts +0 -4
- package/src/src/config.ts +0 -41
- package/src/src/file-builder.ts +0 -108
- package/src/src/generators/file-generator.ts +0 -29
- package/src/src/generators/index.ts +0 -4
- package/src/src/generators/models/args.ts +0 -128
- package/src/src/generators/models/index.ts +0 -4
- package/src/src/generators/models/model-generator.ts +0 -602
- package/src/src/generators/models/models-generator.ts +0 -65
- package/src/src/generators/models/models.ts +0 -95
- package/src/src/generators/services/okhttp3-clients/args.ts +0 -78
- package/src/src/generators/services/okhttp3-clients/index.ts +0 -4
- package/src/src/generators/services/okhttp3-clients/models.ts +0 -62
- package/src/src/generators/services/okhttp3-clients/okhttp3-client-generator.ts +0 -557
- package/src/src/generators/services/okhttp3-clients/okhttp3-clients-generator.ts +0 -130
- package/src/src/generators/services/okhttp3-clients/refs.ts +0 -55
- package/src/src/generators/services/spring-controllers/args.ts +0 -73
- package/src/src/generators/services/spring-controllers/index.ts +0 -4
- package/src/src/generators/services/spring-controllers/models.ts +0 -58
- package/src/src/generators/services/spring-controllers/spring-controller-generator.ts +0 -653
- package/src/src/generators/services/spring-controllers/spring-controllers-generator.ts +0 -70
- package/src/src/import-collection.test.ts +0 -116
- package/src/src/import-collection.ts +0 -98
- package/src/src/types.ts +0 -3
- package/src/src/utils.ts +0 -39
- package/src/tests/openapi-models.test.ts +0 -63
- package/test_runner.js +0 -227
|
@@ -1,355 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TestSuiteInternal = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
6
|
-
const dntShim = tslib_1.__importStar(require("../../../../../_dnt.test_shims.js"));
|
|
7
|
-
const assertion_state_js_1 = require("../../internal/1.0.5/assertion_state.js");
|
|
8
|
-
const assertion_error_js_1 = require("../../assert/1.0.8/assertion_error.js");
|
|
9
|
-
const assertionState = (0, assertion_state_js_1.getAssertionState)();
|
|
10
|
-
/**
|
|
11
|
-
* An internal representation of a group of tests.
|
|
12
|
-
*/
|
|
13
|
-
class TestSuiteInternal {
|
|
14
|
-
constructor(describe) {
|
|
15
|
-
Object.defineProperty(this, "symbol", {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
configurable: true,
|
|
18
|
-
writable: true,
|
|
19
|
-
value: void 0
|
|
20
|
-
});
|
|
21
|
-
Object.defineProperty(this, "describe", {
|
|
22
|
-
enumerable: true,
|
|
23
|
-
configurable: true,
|
|
24
|
-
writable: true,
|
|
25
|
-
value: void 0
|
|
26
|
-
});
|
|
27
|
-
Object.defineProperty(this, "steps", {
|
|
28
|
-
enumerable: true,
|
|
29
|
-
configurable: true,
|
|
30
|
-
writable: true,
|
|
31
|
-
value: void 0
|
|
32
|
-
});
|
|
33
|
-
Object.defineProperty(this, "hasOnlyStep", {
|
|
34
|
-
enumerable: true,
|
|
35
|
-
configurable: true,
|
|
36
|
-
writable: true,
|
|
37
|
-
value: void 0
|
|
38
|
-
});
|
|
39
|
-
this.describe = describe;
|
|
40
|
-
this.steps = [];
|
|
41
|
-
this.hasOnlyStep = false;
|
|
42
|
-
const { suite } = describe;
|
|
43
|
-
if (suite && !TestSuiteInternal.suites.has(suite.symbol)) {
|
|
44
|
-
throw new Error("Cannot construct Test Suite: suite does not represent a registered test suite");
|
|
45
|
-
}
|
|
46
|
-
const testSuite = suite
|
|
47
|
-
? TestSuiteInternal.suites.get(suite.symbol)
|
|
48
|
-
: TestSuiteInternal.current;
|
|
49
|
-
this.symbol = Symbol();
|
|
50
|
-
TestSuiteInternal.suites.set(this.symbol, this);
|
|
51
|
-
const { fn } = describe;
|
|
52
|
-
if (fn) {
|
|
53
|
-
const temp = TestSuiteInternal.current;
|
|
54
|
-
TestSuiteInternal.current = this;
|
|
55
|
-
try {
|
|
56
|
-
// deno-lint-ignore no-explicit-any
|
|
57
|
-
const value = fn();
|
|
58
|
-
if (value instanceof Promise) {
|
|
59
|
-
throw new Error('Returning a Promise from "describe" is not supported: tests must be defined synchronously');
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
finally {
|
|
63
|
-
TestSuiteInternal.current = temp;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
if (testSuite) {
|
|
67
|
-
TestSuiteInternal.addStep(testSuite, this);
|
|
68
|
-
}
|
|
69
|
-
else {
|
|
70
|
-
const { name, ignore, permissions, sanitizeExit, sanitizeOps, sanitizeResources, } = describe;
|
|
71
|
-
let { only } = describe;
|
|
72
|
-
if (!ignore && this.hasOnlyStep) {
|
|
73
|
-
only = true;
|
|
74
|
-
}
|
|
75
|
-
const options = {
|
|
76
|
-
name,
|
|
77
|
-
fn: async (t) => {
|
|
78
|
-
TestSuiteInternal.runningCount++;
|
|
79
|
-
try {
|
|
80
|
-
const context = {};
|
|
81
|
-
const { beforeAll } = this.describe;
|
|
82
|
-
if (typeof beforeAll === "function") {
|
|
83
|
-
await beforeAll.call(context);
|
|
84
|
-
}
|
|
85
|
-
else if (beforeAll) {
|
|
86
|
-
for (const hook of beforeAll) {
|
|
87
|
-
await hook.call(context);
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
try {
|
|
91
|
-
TestSuiteInternal.active.push(this.symbol);
|
|
92
|
-
await TestSuiteInternal.run(this, context, t);
|
|
93
|
-
}
|
|
94
|
-
finally {
|
|
95
|
-
TestSuiteInternal.active.pop();
|
|
96
|
-
const { afterAll } = this.describe;
|
|
97
|
-
if (typeof afterAll === "function") {
|
|
98
|
-
await afterAll.call(context);
|
|
99
|
-
}
|
|
100
|
-
else if (afterAll) {
|
|
101
|
-
for (const hook of afterAll) {
|
|
102
|
-
await hook.call(context);
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
finally {
|
|
108
|
-
TestSuiteInternal.runningCount--;
|
|
109
|
-
}
|
|
110
|
-
},
|
|
111
|
-
};
|
|
112
|
-
if (ignore !== undefined) {
|
|
113
|
-
options.ignore = ignore;
|
|
114
|
-
}
|
|
115
|
-
if (only !== undefined) {
|
|
116
|
-
options.only = only;
|
|
117
|
-
}
|
|
118
|
-
if (permissions !== undefined) {
|
|
119
|
-
options.permissions = permissions;
|
|
120
|
-
}
|
|
121
|
-
if (sanitizeExit !== undefined) {
|
|
122
|
-
options.sanitizeExit = sanitizeExit;
|
|
123
|
-
}
|
|
124
|
-
if (sanitizeOps !== undefined) {
|
|
125
|
-
options.sanitizeOps = sanitizeOps;
|
|
126
|
-
}
|
|
127
|
-
if (sanitizeResources !== undefined) {
|
|
128
|
-
options.sanitizeResources = sanitizeResources;
|
|
129
|
-
}
|
|
130
|
-
TestSuiteInternal.registerTest(options);
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
/** This is used internally for testing this module. */
|
|
134
|
-
static reset() {
|
|
135
|
-
TestSuiteInternal.runningCount = 0;
|
|
136
|
-
TestSuiteInternal.started = false;
|
|
137
|
-
TestSuiteInternal.current = null;
|
|
138
|
-
TestSuiteInternal.active = [];
|
|
139
|
-
}
|
|
140
|
-
/** This is used internally to register tests. */
|
|
141
|
-
static registerTest(options) {
|
|
142
|
-
options = { ...options };
|
|
143
|
-
if (options.only === undefined) {
|
|
144
|
-
delete options.only;
|
|
145
|
-
}
|
|
146
|
-
if (options.permissions === undefined) {
|
|
147
|
-
delete options.permissions;
|
|
148
|
-
}
|
|
149
|
-
if (options.ignore === undefined) {
|
|
150
|
-
delete options.ignore;
|
|
151
|
-
}
|
|
152
|
-
if (options.sanitizeExit === undefined) {
|
|
153
|
-
delete options.sanitizeExit;
|
|
154
|
-
}
|
|
155
|
-
if (options.sanitizeOps === undefined) {
|
|
156
|
-
delete options.sanitizeOps;
|
|
157
|
-
}
|
|
158
|
-
if (options.sanitizeResources === undefined) {
|
|
159
|
-
delete options.sanitizeResources;
|
|
160
|
-
}
|
|
161
|
-
dntShim.Deno.test(options);
|
|
162
|
-
}
|
|
163
|
-
/** Updates all steps within top level suite to have ignore set to true if only is not set to true on step. */
|
|
164
|
-
static addingOnlyStep(suite) {
|
|
165
|
-
if (!suite.hasOnlyStep) {
|
|
166
|
-
for (let i = 0; i < suite.steps.length; i++) {
|
|
167
|
-
const step = suite.steps[i];
|
|
168
|
-
if (!(step instanceof TestSuiteInternal) && !step.only) {
|
|
169
|
-
suite.steps.splice(i--, 1);
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
suite.hasOnlyStep = true;
|
|
173
|
-
}
|
|
174
|
-
const parentSuite = suite.describe.suite;
|
|
175
|
-
const parentTestSuite = parentSuite &&
|
|
176
|
-
TestSuiteInternal.suites.get(parentSuite.symbol);
|
|
177
|
-
if (parentTestSuite) {
|
|
178
|
-
TestSuiteInternal.addingOnlyStep(parentTestSuite);
|
|
179
|
-
}
|
|
180
|
-
}
|
|
181
|
-
/** This is used internally to add steps to a test suite. */
|
|
182
|
-
static addStep(suite, step) {
|
|
183
|
-
if (!suite.hasOnlyStep) {
|
|
184
|
-
if (step instanceof TestSuiteInternal) {
|
|
185
|
-
if (step.hasOnlyStep || step.describe.only) {
|
|
186
|
-
TestSuiteInternal.addingOnlyStep(suite);
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
else {
|
|
190
|
-
if (step.only)
|
|
191
|
-
TestSuiteInternal.addingOnlyStep(suite);
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
if (!(suite.hasOnlyStep && !(step instanceof TestSuiteInternal) && !step.only)) {
|
|
195
|
-
suite.steps.push(step);
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
/** This is used internally to add hooks to a test suite. */
|
|
199
|
-
static setHook(suite, name, fn) {
|
|
200
|
-
if (suite.describe[name]) {
|
|
201
|
-
if (typeof suite.describe[name] === "function") {
|
|
202
|
-
suite.describe[name] = [
|
|
203
|
-
suite.describe[name],
|
|
204
|
-
];
|
|
205
|
-
}
|
|
206
|
-
suite.describe[name].push(fn);
|
|
207
|
-
}
|
|
208
|
-
else {
|
|
209
|
-
suite.describe[name] = fn;
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
/** This is used internally to run all steps for a test suite. */
|
|
213
|
-
static async run(suite, context, t) {
|
|
214
|
-
const hasOnly = suite.hasOnlyStep || suite.describe.only || false;
|
|
215
|
-
for (const step of suite.steps) {
|
|
216
|
-
if (hasOnly && step instanceof TestSuiteInternal &&
|
|
217
|
-
!(step.hasOnlyStep || step.describe.only || false)) {
|
|
218
|
-
continue;
|
|
219
|
-
}
|
|
220
|
-
const { name, fn, ignore, permissions, sanitizeExit, sanitizeOps, sanitizeResources, } = step instanceof TestSuiteInternal ? step.describe : step;
|
|
221
|
-
const options = {
|
|
222
|
-
name,
|
|
223
|
-
fn: async (t) => {
|
|
224
|
-
if (permissions) {
|
|
225
|
-
throw new Error("permissions option not available for nested tests");
|
|
226
|
-
}
|
|
227
|
-
context = { ...context };
|
|
228
|
-
if (step instanceof TestSuiteInternal) {
|
|
229
|
-
const { beforeAll } = step.describe;
|
|
230
|
-
if (typeof beforeAll === "function") {
|
|
231
|
-
await beforeAll.call(context);
|
|
232
|
-
}
|
|
233
|
-
else if (beforeAll) {
|
|
234
|
-
for (const hook of beforeAll) {
|
|
235
|
-
await hook.call(context);
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
try {
|
|
239
|
-
TestSuiteInternal.active.push(step.symbol);
|
|
240
|
-
await TestSuiteInternal.run(step, context, t);
|
|
241
|
-
}
|
|
242
|
-
finally {
|
|
243
|
-
TestSuiteInternal.active.pop();
|
|
244
|
-
const { afterAll } = step.describe;
|
|
245
|
-
if (typeof afterAll === "function") {
|
|
246
|
-
await afterAll.call(context);
|
|
247
|
-
}
|
|
248
|
-
else if (afterAll) {
|
|
249
|
-
for (const hook of afterAll) {
|
|
250
|
-
await hook.call(context);
|
|
251
|
-
}
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
}
|
|
255
|
-
else {
|
|
256
|
-
await TestSuiteInternal.runTest(t, fn, context);
|
|
257
|
-
}
|
|
258
|
-
},
|
|
259
|
-
};
|
|
260
|
-
if (ignore !== undefined) {
|
|
261
|
-
options.ignore = ignore;
|
|
262
|
-
}
|
|
263
|
-
if (sanitizeExit !== undefined) {
|
|
264
|
-
options.sanitizeExit = sanitizeExit;
|
|
265
|
-
}
|
|
266
|
-
if (sanitizeOps !== undefined) {
|
|
267
|
-
options.sanitizeOps = sanitizeOps;
|
|
268
|
-
}
|
|
269
|
-
if (sanitizeResources !== undefined) {
|
|
270
|
-
options.sanitizeResources = sanitizeResources;
|
|
271
|
-
}
|
|
272
|
-
await t.step(options);
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
static async runTest(t, fn, context, activeIndex = 0) {
|
|
276
|
-
const suite = TestSuiteInternal.active[activeIndex];
|
|
277
|
-
const testSuite = suite && TestSuiteInternal.suites.get(suite);
|
|
278
|
-
if (testSuite) {
|
|
279
|
-
if (activeIndex === 0)
|
|
280
|
-
context = { ...context };
|
|
281
|
-
const { beforeEach } = testSuite.describe;
|
|
282
|
-
if (typeof beforeEach === "function") {
|
|
283
|
-
await beforeEach.call(context);
|
|
284
|
-
}
|
|
285
|
-
else if (beforeEach) {
|
|
286
|
-
for (const hook of beforeEach) {
|
|
287
|
-
await hook.call(context);
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
try {
|
|
291
|
-
await TestSuiteInternal.runTest(t, fn, context, activeIndex + 1);
|
|
292
|
-
}
|
|
293
|
-
finally {
|
|
294
|
-
const { afterEach } = testSuite.describe;
|
|
295
|
-
if (typeof afterEach === "function") {
|
|
296
|
-
await afterEach.call(context);
|
|
297
|
-
}
|
|
298
|
-
else if (afterEach) {
|
|
299
|
-
for (const hook of afterEach) {
|
|
300
|
-
await hook.call(context);
|
|
301
|
-
}
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
|
-
}
|
|
305
|
-
else {
|
|
306
|
-
await fn.call(context, t);
|
|
307
|
-
}
|
|
308
|
-
if (assertionState.checkAssertionErrorState()) {
|
|
309
|
-
throw new assertion_error_js_1.AssertionError("Expected at least one assertion to be called but received none");
|
|
310
|
-
}
|
|
311
|
-
if (assertionState.checkAssertionCountSatisfied()) {
|
|
312
|
-
throw new assertion_error_js_1.AssertionError(`Expected at least ${assertionState.assertionCount} assertion to be called, ` +
|
|
313
|
-
`but received ${assertionState.assertionTriggeredCount}`);
|
|
314
|
-
}
|
|
315
|
-
assertionState.resetAssertionState();
|
|
316
|
-
}
|
|
317
|
-
}
|
|
318
|
-
exports.TestSuiteInternal = TestSuiteInternal;
|
|
319
|
-
/** Stores how many test suites are executing. */
|
|
320
|
-
Object.defineProperty(TestSuiteInternal, "runningCount", {
|
|
321
|
-
enumerable: true,
|
|
322
|
-
configurable: true,
|
|
323
|
-
writable: true,
|
|
324
|
-
value: 0
|
|
325
|
-
});
|
|
326
|
-
/** If a test has been registered yet. Block adding global hooks if a test has been registered. */
|
|
327
|
-
Object.defineProperty(TestSuiteInternal, "started", {
|
|
328
|
-
enumerable: true,
|
|
329
|
-
configurable: true,
|
|
330
|
-
writable: true,
|
|
331
|
-
value: false
|
|
332
|
-
});
|
|
333
|
-
/** A map of all test suites by symbol. */
|
|
334
|
-
// deno-lint-ignore no-explicit-any
|
|
335
|
-
Object.defineProperty(TestSuiteInternal, "suites", {
|
|
336
|
-
enumerable: true,
|
|
337
|
-
configurable: true,
|
|
338
|
-
writable: true,
|
|
339
|
-
value: new Map()
|
|
340
|
-
});
|
|
341
|
-
/** The current test suite being registered. */
|
|
342
|
-
// deno-lint-ignore no-explicit-any
|
|
343
|
-
Object.defineProperty(TestSuiteInternal, "current", {
|
|
344
|
-
enumerable: true,
|
|
345
|
-
configurable: true,
|
|
346
|
-
writable: true,
|
|
347
|
-
value: null
|
|
348
|
-
});
|
|
349
|
-
/** The stack of tests that are actively running. */
|
|
350
|
-
Object.defineProperty(TestSuiteInternal, "active", {
|
|
351
|
-
enumerable: true,
|
|
352
|
-
configurable: true,
|
|
353
|
-
writable: true,
|
|
354
|
-
value: []
|
|
355
|
-
});
|