ember-source 4.1.0-alpha.6 → 4.2.0-alpha.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/CHANGELOG.md +81 -63
- package/blueprints/acceptance-test/qunit-files/tests/acceptance/__name__-test.js +1 -1
- package/blueprints/acceptance-test/qunit-rfc-232-files/tests/acceptance/__name__-test.js +1 -1
- package/blueprints/component-test/qunit-files/__root__/__testType__/__path__/__test__.js +3 -3
- package/blueprints/helper-test/index.js +4 -22
- package/blueprints/helper-test/mocha-0.12-files/__root__/__testType__/__collection__/__name__-test.js +1 -13
- package/blueprints/helper-test/mocha-files/__root__/__testType__/__collection__/__name__-test.js +0 -13
- package/blueprints/helper-test/mocha-rfc-232-files/__root__/__testType__/__collection__/__name__-test.js +2 -12
- package/blueprints/helper-test/qunit-files/__root__/__testType__/__collection__/__name__-test.js +2 -13
- package/blueprints/helper-test/qunit-rfc-232-files/__root__/__testType__/__collection__/__name__-test.js +2 -14
- package/build-metadata.json +3 -3
- package/dist/dependencies/@glimmer/manager.js +19 -98
- package/dist/dependencies/@glimmer/opcode-compiler.js +9 -146
- package/dist/dependencies/@glimmer/runtime.js +1 -55
- package/dist/dependencies/@glimmer/validator.js +19 -51
- package/dist/ember-template-compiler.js +366 -691
- package/dist/ember-template-compiler.map +1 -1
- package/dist/ember-testing.js +1 -1
- package/dist/ember-testing.map +1 -1
- package/dist/ember.debug.js +3259 -6349
- package/dist/ember.debug.map +1 -1
- package/dist/header/license.js +1 -1
- package/dist/packages/@ember/-internals/environment/index.js +0 -15
- package/dist/packages/@ember/-internals/glimmer/index.js +4815 -6763
- package/dist/packages/@ember/-internals/metal/index.js +57 -103
- package/dist/packages/@ember/-internals/routing/lib/location/api.js +10 -1
- package/dist/packages/@ember/-internals/routing/lib/location/none_location.js +7 -2
- package/dist/packages/@ember/-internals/routing/lib/services/router.js +1 -1
- package/dist/packages/@ember/-internals/routing/lib/services/routing.js +1 -1
- package/dist/packages/@ember/-internals/routing/lib/system/route.js +3 -42
- package/dist/packages/@ember/-internals/routing/lib/system/router.js +36 -46
- package/dist/packages/@ember/-internals/runtime/lib/mixins/array.js +2 -173
- package/dist/packages/@ember/-internals/runtime/lib/mixins/target_action_support.js +3 -43
- package/dist/packages/@ember/-internals/runtime/lib/system/array_proxy.js +8 -15
- package/dist/packages/@ember/-internals/utils/index.js +0 -3
- package/dist/packages/@ember/-internals/views/index.js +0 -1
- package/dist/packages/@ember/-internals/views/lib/mixins/view_support.js +4 -4
- package/dist/packages/@ember/application/lib/application.js +7 -8
- package/dist/packages/@ember/canary-features/index.js +2 -4
- package/dist/packages/@ember/component/index.js +1 -1
- package/dist/packages/@ember/deprecated-features/index.js +0 -1
- package/dist/packages/@ember/destroyable/index.js +15 -4
- package/dist/packages/@ember/engine/index.js +1 -2
- package/dist/packages/@ember/routing/index.js +1 -1
- package/dist/packages/@glimmer/tracking/index.js +203 -1
- package/dist/packages/ember/index.js +9 -61
- package/dist/packages/ember/version.js +1 -1
- package/docs/data.json +430 -1382
- package/lib/index.js +3 -29
- package/package.json +17 -17
- package/dist/packages/@ember/-internals/views/lib/mixins/text_support.js +0 -345
- package/dist/packages/@ember/component/checkbox.js +0 -17
- package/dist/packages/@ember/component/text-area.js +0 -17
- package/dist/packages/@ember/component/text-field.js +0 -17
- package/dist/packages/@ember/routing/link-component.js +0 -17
package/CHANGELOG.md
CHANGED
|
@@ -1,82 +1,100 @@
|
|
|
1
1
|
# Ember Changelog
|
|
2
2
|
|
|
3
|
-
### v4.
|
|
3
|
+
### v4.1.0-beta.1 (November 19, 2021)
|
|
4
4
|
|
|
5
|
-
- [#
|
|
5
|
+
- [#19772](https://github.com/emberjs/ember.js/pull/19772) / [#19826](https://github.com/emberjs/ember.js/pull/19826) [FEATURE] Add a `@cached` decorator per [RFC #0566](https://github.com/emberjs/rfcs/blob/af64915b5ecde010fce09309a47ee6d2447588d0/text/0566-memo-decorator.md).
|
|
6
|
+
- [#19471](https://github.com/emberjs/ember.js/pull/19471) / [#19834](https://github.com/emberjs/ember.js/pull/19834) [FEATURE] Add `refresh` method to the Router Service per [RFC #0631](https://github.com/emberjs/rfcs/blob/master/text/0631-refresh-method-for-router-service.md).
|
|
7
|
+
- [#19776](https://github.com/emberjs/ember.js/pull/19776) [FEATURE] Provide `service` export from `@ember/service` in favour of `inject` implementing [RFC #0752](https://github.com/emberjs/rfcs/blob/master/text/0752-inject-service.md).
|
|
8
|
+
- [#19510](https://github.com/emberjs/ember.js/pull/19510) [DEPRECATION] Deprecate auto location per [RFC #0711](https://github.com/emberjs/rfcs/blob/master/text/0711-deprecate-auto-location.md).
|
|
9
|
+
- [#17570](https://github.com/emberjs/ember.js/pull/17570) [BUGFIX] Passing ObjectProxy with a property size to `isEmpty` would throw assertion
|
|
10
|
+
- [#18269](https://github.com/emberjs/ember.js/pull/18269) [BUGFIX] Fix for when query params are using a nested value
|
|
11
|
+
- [#19787](https://github.com/emberjs/ember.js/pull/19787) Setup basic infrastructure to ensure destroyables destroyed
|
|
6
12
|
|
|
7
|
-
### v4.0.0
|
|
8
|
-
|
|
9
|
-
- [#19799](https://github.com/emberjs/ember.js/pull/19799) / [glimmerjs/glimmer-vm#1354](https://github.com/glimmerjs/glimmer-vm/pull/1354) Fixes for errors while precompiling inline templates (introduced in 3.28.2)
|
|
10
|
-
|
|
11
|
-
### v4.0.0-beta.5 (October 11, 2021)
|
|
13
|
+
### v4.0.0 (November 15, 2021)
|
|
12
14
|
|
|
13
15
|
- [#19761](https://github.com/emberjs/ember.js/pull/19761) [BREAKING] Require ember-auto-import >= 2 or higher to enable ember-source to become a v2 addon in the 4.x cycle
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
- [#
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
- [#
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
16
|
+
- [#19706](https://github.com/emberjs/ember.js/pull/19706) [BREAKING] Explicitly drop Node 10 support to match support policy.
|
|
17
|
+
- [BREAKING] Remove deprecated features
|
|
18
|
+
- [#19838](https://github.com/emberjs/ember.js/pull/19838) [CLEANUP] Remove check to see if `ember` is defined as a Bower dependency
|
|
19
|
+
- [#19846](https://github.com/emberjs/ember.js/pull/19846) [CLEANUP] Make using the "classic" edition of Ember throw
|
|
20
|
+
- [#19833](https://github.com/emberjs/ember.js/pull/19833) [CLEANUP] Remove deprecated array observers
|
|
21
|
+
- [#19836](https://github.com/emberjs/ember.js/pull/19836) [CLEANUP] Turn `template-only-glimmer-components` deprecation into an error
|
|
22
|
+
- [#19843](https://github.com/emberjs/ember.js/pull/19843) [CLEANUP] Turn `argument-less-helper-paren-less-invocation` deprecation into an error
|
|
23
|
+
- [#19749](https://github.com/emberjs/ember.js/pull/19749) [CLEANUP] Remove `deprecate-router-events` support code
|
|
24
|
+
- [#19762](https://github.com/emberjs/ember.js/pull/19762) [CLEANUP] Update GlimmerVM to 0.81
|
|
25
|
+
- removes deprecation of mutations during helper compute
|
|
26
|
+
- removes deprecation of mutations during unknownProperty
|
|
27
|
+
- `@glimmer/integration-tests`, `@glimmer/manager`, `@glimmer/validator`
|
|
28
|
+
* [#1330](https://github.com/glimmerjs/glimmer-vm/pull/1330) Remove deprecated support for mutation after consumption during certain manager hooks ([@snewcomer](https://github.com/snewcomer))
|
|
29
|
+
- `@glimmer/manager`
|
|
30
|
+
* [#1328](https://github.com/glimmerjs/glimmer-vm/pull/1328) Remove deprecated Component Manager version 3.4 ([@nlfurniss](https://github.com/nlfurniss))
|
|
31
|
+
- `@glimmer/integration-tests`, `@glimmer/manager`
|
|
32
|
+
* [#1329](https://github.com/glimmerjs/glimmer-vm/pull/1329) Remove deprecated Modifier Manager version 3.13 ([@nlfurniss](https://github.com/nlfurniss))
|
|
33
|
+
- [#19806](https://github.com/emberjs/ember.js/pull/19806) [CLEANUP] Drop export of built-ins, remove legacy components
|
|
34
|
+
- [#19808](https://github.com/emberjs/ember.js/pull/19808) [CLEANUP] Remove the `--test-type` option from the helper blueprint
|
|
35
|
+
- [#19677](https://github.com/emberjs/ember.js/pull/19677) [CLEANUP] Remove jQuery from build
|
|
36
|
+
- [#19708](https://github.com/emberjs/ember.js/pull/19708) [CLEANUP] Remove class-binding-and-class-name-bindings-in-templates
|
|
37
|
+
- [#19650](https://github.com/emberjs/ember.js/pull/19650) [CLEANUP] Remove deprecated mouse events
|
|
38
|
+
- [#19675](https://github.com/emberjs/ember.js/pull/19675) [CLEANUP] Remove jQuery usage from ember-testing
|
|
39
|
+
- [#19704](https://github.com/emberjs/ember.js/pull/19704) [CLEANUP] Remove template-compiler.registerPlugin
|
|
40
|
+
- [#19707](https://github.com/emberjs/ember.js/pull/19707) [CLEANUP] Remove Application Controller Router Properties
|
|
41
|
+
- [#19528](https://github.com/emberjs/ember.js/pull/19528) [CLEANUP] Remove Logger
|
|
42
|
+
- [#19558](https://github.com/emberjs/ember.js/pull/19558) [CLEANUP] Remove IE11 support
|
|
43
|
+
- [#19563](https://github.com/emberjs/ember.js/pull/19563) [CLEANUP] Remove internal Ember.assign usage
|
|
44
|
+
- [#19636](https://github.com/emberjs/ember.js/pull/19636) [CLEANUP] Remove copy & Copyable
|
|
45
|
+
- [#19638](https://github.com/emberjs/ember.js/pull/19638) [CLEANUP] Remove deprecated with
|
|
46
|
+
- [#19639](https://github.com/emberjs/ember.js/pull/19639) [CLEANUP] Removes deprecated Private INVOKE API
|
|
47
|
+
- [#19640](https://github.com/emberjs/ember.js/pull/19640) [CLEANUP] Remove old deprecations import path
|
|
48
|
+
- [#19641](https://github.com/emberjs/ember.js/pull/19641) [CLEANUP] Remove isVisible
|
|
49
|
+
- [#19642](https://github.com/emberjs/ember.js/pull/19642) [CLEANUP] Remove aliasMethod
|
|
50
|
+
- [#19643](https://github.com/emberjs/ember.js/pull/19643) [CLEANUP] Remove deprecate without for and since
|
|
51
|
+
- [#19644](https://github.com/emberjs/ember.js/pull/19644) [CLEANUP] Remove -in-element
|
|
52
|
+
- [#19645](https://github.com/emberjs/ember.js/pull/19645) [CLEANUP] Remove tryInvoke
|
|
53
|
+
- [#19646](https://github.com/emberjs/ember.js/pull/19646) [CLEANUP] Remove loc
|
|
54
|
+
- [#19647](https://github.com/emberjs/ember.js/pull/19647) [CLEANUP] Remove Ember.merge
|
|
55
|
+
- [#19648](https://github.com/emberjs/ember.js/pull/19648) [CLEANUP] Remove getWithDefault
|
|
56
|
+
- [#19651](https://github.com/emberjs/ember.js/pull/19651) [CLEANUP] Remove LEGACY_OWNER
|
|
57
|
+
- [#19652](https://github.com/emberjs/ember.js/pull/19652) [CLEANUP] Remove Globals Resolver
|
|
58
|
+
- [#19653](https://github.com/emberjs/ember.js/pull/19653) [CLEANUP] Remove run and computed dot access
|
|
59
|
+
- [#19654](https://github.com/emberjs/ember.js/pull/19654) [CLEANUP] Remove @ember/string methods from native prototype
|
|
60
|
+
- [#19655](https://github.com/emberjs/ember.js/pull/19655) [CLEANUP] Remove meta-destruction-apis
|
|
61
|
+
- [#19656](https://github.com/emberjs/ember.js/pull/19656) [CLEANUP] Remove string-based setComponentManager
|
|
62
|
+
- [#19657](https://github.com/emberjs/ember.js/pull/19657) [CLEANUP] Remove hasBlock and hasBlockParams
|
|
63
|
+
- [#19658](https://github.com/emberjs/ember.js/pull/19658) [CLEANUP] Remove sendAction and string action passing
|
|
64
|
+
- [#19659](https://github.com/emberjs/ember.js/pull/19659) [CLEANUP] Remove renderTemplate, disconnectOutlet, render
|
|
65
|
+
- [#19660](https://github.com/emberjs/ember.js/pull/19660) [CLEANUP] Remove attrs/attrs-arg-access
|
|
66
|
+
- [#19661](https://github.com/emberjs/ember.js/pull/19661) [CLEANUP] Remove EMBER_EXTEND_PROTOTYPES
|
|
67
|
+
- [#19663](https://github.com/emberjs/ember.js/pull/19663) [CLEANUP] Remove function prototype extensions
|
|
68
|
+
- [#19665](https://github.com/emberjs/ember.js/pull/19665) [CLEANUP] Remove deprecated jQuery integration
|
|
69
|
+
- [#19666](https://github.com/emberjs/ember.js/pull/19666) [CLEANUP] Remove jQuery integration in EventDispatcher
|
|
70
|
+
- [#19667](https://github.com/emberjs/ember.js/pull/19667) [CLEANUP] Cleanup IE11 leftovers
|
|
71
|
+
- [#19670](https://github.com/emberjs/ember.js/pull/19670) [CLEANUP] Remove .volatile()
|
|
72
|
+
- [#19671](https://github.com/emberjs/ember.js/pull/19671) [CLEANUP] Remove .property()
|
|
73
|
+
- [#19673](https://github.com/emberjs/ember.js/pull/19673) [CLEANUP] Remove computed deep each
|
|
74
|
+
- [#19674](https://github.com/emberjs/ember.js/pull/19674) [CLEANUP] Remove ability to override computed property
|
|
75
|
+
- [#19678](https://github.com/emberjs/ember.js/pull/19678) [CLEANUP] Remove window.Ember global
|
|
76
|
+
- [#19695](https://github.com/emberjs/ember.js/pull/19695) [CLEANUP] Remove {{partial}}
|
|
77
|
+
- [#19691](https://github.com/emberjs/ember.js/pull/19691) Add build assertion against `{{outlet named}}`
|
|
25
78
|
- [#19680](https://github.com/emberjs/ember.js/pull/19680) [DEPRECATION] Deprecate owner.inject per [RFC #680](https://github.com/emberjs/rfcs/blob/sn/owner-inject-deprecation/text/0680-implicit-injection-deprecation.md#1-deprecate-implicit-injection-on-target-object) and cleanup related deprecations that are `until: 4.0.0`.
|
|
26
|
-
- [#19706](https://github.com/emberjs/ember.js/pull/19706) [BUGFIX] Explicitly drop Node 10 support to match support policy.
|
|
27
|
-
- [#19650](https://github.com/emberjs/ember.js/pull/19650) [CLEANUP] Remove deprecated mouse events
|
|
28
|
-
- [#19675](https://github.com/emberjs/ember.js/pull/19675) [CLEANUP] Remove jQuery usage from ember-testing
|
|
29
|
-
- [#19704](https://github.com/emberjs/ember.js/pull/19704) [CLEANUP] Remove template-compiler.registerPlugin
|
|
30
|
-
- [#19707](https://github.com/emberjs/ember.js/pull/19707) [CLEANUP] Remove Application Controller Router Properties
|
|
31
|
-
|
|
32
|
-
### v4.0.0-beta.1 (August 17, 2021)
|
|
33
|
-
|
|
34
79
|
- [#19649](https://github.com/emberjs/ember.js/pull/19649) / [#19692](https://github.com/emberjs/ember.js/pull/19692) [DEPRECATION] Add deprecation warning to Ember.assign implementing [RFC #750](https://github.com/emberjs/rfcs/blob/master/text/0750-deprecate-ember-assign.md).
|
|
80
|
+
- [#19825](https://github.com/emberjs/ember.js/pull/19825) [BUGFIX] Replace `assert.equal` in blueprints with `assert.strictEqual` to pass eslint-plugin-qunit v7 on generation
|
|
35
81
|
- [#19227](https://github.com/emberjs/ember.js/pull/19227) [BUGFIX] Enable global event dispatcher listeners to be lazily created fixing Passive Listener Violation in Chrome
|
|
36
82
|
- [#19542](https://github.com/emberjs/ember.js/pull/19542) [BUGFIX] Fix initializer test blueprints
|
|
37
83
|
- [#19589](https://github.com/emberjs/ember.js/pull/19589) [BUGFIX] Don’t include type-tests in build output
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
- [#
|
|
42
|
-
- [#19638](https://github.com/emberjs/ember.js/pull/19638) [CLEANUP] Remove deprecated with
|
|
43
|
-
- [#19639](https://github.com/emberjs/ember.js/pull/19639) [CLEANUP] Removes deprecated Private INVOKE API
|
|
44
|
-
- [#19640](https://github.com/emberjs/ember.js/pull/19640) [CLEANUP] Remove old deprecations import path
|
|
45
|
-
- [#19641](https://github.com/emberjs/ember.js/pull/19641) [CLEANUP] Remove isVisible
|
|
46
|
-
- [#19642](https://github.com/emberjs/ember.js/pull/19642) [CLEANUP] Remove aliasMethod
|
|
47
|
-
- [#19643](https://github.com/emberjs/ember.js/pull/19643) [CLEANUP] Remove deprecate without for and since
|
|
48
|
-
- [#19644](https://github.com/emberjs/ember.js/pull/19644) [CLEANUP] Remove -in-element
|
|
49
|
-
- [#19645](https://github.com/emberjs/ember.js/pull/19645) [CLEANUP] Remove tryInvoke
|
|
50
|
-
- [#19646](https://github.com/emberjs/ember.js/pull/19646) [CLEANUP] Remove loc
|
|
51
|
-
- [#19647](https://github.com/emberjs/ember.js/pull/19647) [CLEANUP] Remove Ember.merge
|
|
52
|
-
- [#19648](https://github.com/emberjs/ember.js/pull/19648) [CLEANUP] Remove getWithDefault
|
|
53
|
-
- [#19651](https://github.com/emberjs/ember.js/pull/19651) [CLEANUP] Remove LEGACY_OWNER
|
|
54
|
-
- [#19652](https://github.com/emberjs/ember.js/pull/19652) [CLEANUP] Remove Globals Resolver
|
|
55
|
-
- [#19653](https://github.com/emberjs/ember.js/pull/19653) [CLEANUP] Remove run and computed dot access
|
|
56
|
-
- [#19654](https://github.com/emberjs/ember.js/pull/19654) [CLEANUP] Remove @ember/string methods from native prototype
|
|
57
|
-
- [#19655](https://github.com/emberjs/ember.js/pull/19655) [CLEANUP] Remove meta-destruction-apis
|
|
58
|
-
- [#19656](https://github.com/emberjs/ember.js/pull/19656) [CLEANUP] Remove string-based setComponentManager
|
|
59
|
-
- [#19657](https://github.com/emberjs/ember.js/pull/19657) [CLEANUP] Remove hasBlock and hasBlockParams
|
|
60
|
-
- [#19658](https://github.com/emberjs/ember.js/pull/19658) [CLEANUP] Remove sendAction and string action passing
|
|
61
|
-
- [#19659](https://github.com/emberjs/ember.js/pull/19659) [CLEANUP] Remove renderTemplate, disconnectOutlet, render
|
|
62
|
-
- [#19660](https://github.com/emberjs/ember.js/pull/19660) [CLEANUP] Remove attrs/attrs-arg-access
|
|
63
|
-
- [#19661](https://github.com/emberjs/ember.js/pull/19661) [CLEANUP] Remove EMBER_EXTEND_PROTOTYPES
|
|
64
|
-
- [#19663](https://github.com/emberjs/ember.js/pull/19663) [CLEANUP] Remove function prototype extensions
|
|
65
|
-
- [#19665](https://github.com/emberjs/ember.js/pull/19665) [CLEANUP] Remove deprecated jQuery integration
|
|
66
|
-
- [#19666](https://github.com/emberjs/ember.js/pull/19666) [CLEANUP] Remove jQuery integration in EventDispatcher
|
|
67
|
-
- [#19667](https://github.com/emberjs/ember.js/pull/19667) [CLEANUP] Cleanup IE11 leftovers
|
|
68
|
-
- [#19670](https://github.com/emberjs/ember.js/pull/19670) [CLEANUP] Remove .volatile()
|
|
69
|
-
- [#19671](https://github.com/emberjs/ember.js/pull/19671) [CLEANUP] Remove .property()
|
|
70
|
-
- [#19673](https://github.com/emberjs/ember.js/pull/19673) [CLEANUP] Remove computed deep each
|
|
71
|
-
- [#19674](https://github.com/emberjs/ember.js/pull/19674) [CLEANUP] Remove ability to override computed property
|
|
72
|
-
- [#19678](https://github.com/emberjs/ember.js/pull/19678) [CLEANUP] Remove window.Ember global
|
|
73
|
-
- [#19695](https://github.com/emberjs/ember.js/pull/19695) [CLEANUP] Remove {{partial}}
|
|
74
|
-
- [#19691](https://github.com/emberjs/ember.js/pull/19691) Add build assertion against `{{outlet named}}`
|
|
84
|
+
|
|
85
|
+
## v3.28.6 (November 4, 2021)
|
|
86
|
+
|
|
87
|
+
- [#19683](https://github.com/emberjs/ember.js/pull/19683) Ensure super.willDestroy is called correctly in Router's willDestroy
|
|
75
88
|
|
|
76
89
|
## v3.28.5 (November 3, 2021)
|
|
77
90
|
|
|
78
91
|
- [#19820](https://github.com/emberjs/ember.js/pull/19820) Fix memory leak when looking up non-instantiable objects from the owner
|
|
79
92
|
|
|
93
|
+
## v3.28.4 (October 22, 2021)
|
|
94
|
+
|
|
95
|
+
- [#19798](https://github.com/emberjs/ember.js/pull/19798) More fixes for errors while precompiling inline templates (introduced in 3.28.2)
|
|
96
|
+
- [glimmerjs/glimmer-vm@0.80.3](https://github.com/glimmerjs/glimmer-vm/releases/tag/v0.80.3) Improve template compilation speed regression
|
|
97
|
+
|
|
80
98
|
## v3.28.3 (October 22, 2021)
|
|
81
99
|
|
|
82
100
|
- [#19799](https://github.com/emberjs/ember.js/pull/19799) / [glimmerjs/glimmer-vm#1354](https://github.com/glimmerjs/glimmer-vm/pull/1354) Fixes for errors while precompiling inline templates (introduced in 3.28.2)
|
|
@@ -7,6 +7,6 @@ test('visiting /<%= dasherizedModuleName %>', function(assert) {
|
|
|
7
7
|
visit('/<%= dasherizedModuleName %>');
|
|
8
8
|
|
|
9
9
|
andThen(function() {
|
|
10
|
-
assert.
|
|
10
|
+
assert.strictEqual(currentURL(), '/<%= dasherizedModuleName %>');
|
|
11
11
|
});
|
|
12
12
|
});
|
|
@@ -8,6 +8,6 @@ module('<%= friendlyTestName %>', function(hooks) {
|
|
|
8
8
|
test('visiting /<%= dasherizedModuleName %>', async function(assert) {
|
|
9
9
|
await visit('/<%= dasherizedModuleName %>');
|
|
10
10
|
|
|
11
|
-
assert.
|
|
11
|
+
assert.strictEqual(currentURL(), '/<%= dasherizedModuleName %>');
|
|
12
12
|
});
|
|
13
13
|
});
|
|
@@ -13,7 +13,7 @@ test('it renders', function(assert) {
|
|
|
13
13
|
|
|
14
14
|
this.render(hbs`<%= selfCloseComponent(componentName) %>`);
|
|
15
15
|
|
|
16
|
-
assert.
|
|
16
|
+
assert.strictEqual(this.$().text().trim(), '');
|
|
17
17
|
|
|
18
18
|
// Template block usage:
|
|
19
19
|
this.render(hbs`
|
|
@@ -22,10 +22,10 @@ test('it renders', function(assert) {
|
|
|
22
22
|
<%= closeComponent(componentName) %>
|
|
23
23
|
`);
|
|
24
24
|
|
|
25
|
-
assert.
|
|
25
|
+
assert.strictEqual(this.$().text().trim(), 'template block text');<% } else if(testType === 'unit') { %>
|
|
26
26
|
// Creates the component instance
|
|
27
27
|
/*let component =*/ this.subject();
|
|
28
28
|
// Renders the component to the page
|
|
29
29
|
this.render();
|
|
30
|
-
assert.
|
|
30
|
+
assert.strictEqual(this.$().text().trim(), '');<% } %>
|
|
31
31
|
});
|
|
@@ -7,29 +7,15 @@ const semver = require('semver');
|
|
|
7
7
|
const useTestFrameworkDetector = require('../test-framework-detector');
|
|
8
8
|
|
|
9
9
|
module.exports = useTestFrameworkDetector({
|
|
10
|
-
description: 'Generates a helper integration test
|
|
11
|
-
|
|
12
|
-
availableOptions: [
|
|
13
|
-
{
|
|
14
|
-
name: 'test-type',
|
|
15
|
-
type: ['integration', 'unit'],
|
|
16
|
-
default: 'integration',
|
|
17
|
-
aliases: [
|
|
18
|
-
{ i: 'integration' },
|
|
19
|
-
{ u: 'unit' },
|
|
20
|
-
{ integration: 'integration' },
|
|
21
|
-
{ unit: 'unit' },
|
|
22
|
-
],
|
|
23
|
-
},
|
|
24
|
-
],
|
|
10
|
+
description: 'Generates a helper integration test.',
|
|
25
11
|
|
|
26
12
|
fileMapTokens: function () {
|
|
27
13
|
return {
|
|
28
14
|
__root__() {
|
|
29
15
|
return 'tests';
|
|
30
16
|
},
|
|
31
|
-
__testType__(
|
|
32
|
-
return
|
|
17
|
+
__testType__() {
|
|
18
|
+
return 'integration';
|
|
33
19
|
},
|
|
34
20
|
__collection__() {
|
|
35
21
|
return 'helpers';
|
|
@@ -38,9 +24,7 @@ module.exports = useTestFrameworkDetector({
|
|
|
38
24
|
},
|
|
39
25
|
|
|
40
26
|
locals: function (options) {
|
|
41
|
-
let
|
|
42
|
-
let testName = testType === 'integration' ? 'Integration' : 'Unit';
|
|
43
|
-
let friendlyTestName = [testName, 'Helper', options.entity.name].join(' | ');
|
|
27
|
+
let friendlyTestName = ['Integration', 'Helper', options.entity.name].join(' | ');
|
|
44
28
|
let dasherizedModulePrefix = stringUtils.dasherize(options.project.config().modulePrefix);
|
|
45
29
|
|
|
46
30
|
let hbsImportStatement = this._useNamedHbsImport()
|
|
@@ -48,7 +32,6 @@ module.exports = useTestFrameworkDetector({
|
|
|
48
32
|
: "import hbs from 'htmlbars-inline-precompile';";
|
|
49
33
|
|
|
50
34
|
return {
|
|
51
|
-
testType,
|
|
52
35
|
friendlyTestName,
|
|
53
36
|
dasherizedModulePrefix,
|
|
54
37
|
hbsImportStatement,
|
|
@@ -68,7 +51,6 @@ module.exports = useTestFrameworkDetector({
|
|
|
68
51
|
afterInstall: function (options) {
|
|
69
52
|
if (
|
|
70
53
|
!options.dryRun &&
|
|
71
|
-
options.testType === 'integration' &&
|
|
72
54
|
!this._useNamedHbsImport() &&
|
|
73
55
|
isPackageMissing(this, 'ember-cli-htmlbars-inline-precompile')
|
|
74
56
|
) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { expect } from 'chai';
|
|
2
|
-
|
|
2
|
+
import { describe, it } from 'mocha';
|
|
3
3
|
import { setupComponentTest } from 'ember-mocha';
|
|
4
4
|
import hbs from 'htmlbars-inline-precompile';
|
|
5
5
|
|
|
@@ -24,15 +24,3 @@ describe('<%= friendlyTestName %>', function() {
|
|
|
24
24
|
expect(this.$().text().trim()).to.equal('1234');
|
|
25
25
|
});
|
|
26
26
|
});
|
|
27
|
-
<% } else if (testType == 'unit') { %>import { describe, it } from 'mocha';
|
|
28
|
-
import { <%= camelizedModuleName %> } from '<%= dasherizedPackageName %>/helpers/<%= dasherizedModuleName %>';
|
|
29
|
-
|
|
30
|
-
describe('<%= friendlyTestName %>', function() {
|
|
31
|
-
|
|
32
|
-
// TODO: Replace this with your real tests.
|
|
33
|
-
it('works', function() {
|
|
34
|
-
let result = <%= camelizedModuleName %>(42);
|
|
35
|
-
expect(result).to.be.ok;
|
|
36
|
-
});
|
|
37
|
-
});
|
|
38
|
-
<% } %>
|
package/blueprints/helper-test/mocha-files/__root__/__testType__/__collection__/__name__-test.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { expect } from 'chai';
|
|
2
|
-
<% if (testType == 'integration') { %>
|
|
3
2
|
import { describeComponent, it } from 'ember-mocha';
|
|
4
3
|
import hbs from 'htmlbars-inline-precompile';
|
|
5
4
|
|
|
@@ -25,15 +24,3 @@ describeComponent('<%= dasherizedModuleName %>', 'helper:<%= dasherizedModuleNam
|
|
|
25
24
|
});
|
|
26
25
|
}
|
|
27
26
|
);
|
|
28
|
-
<% } else if (testType == 'unit') { %>import { describe, it } from 'mocha';
|
|
29
|
-
import { <%= camelizedModuleName %> } from '<%= dasherizedPackageName %>/helpers/<%= dasherizedModuleName %>';
|
|
30
|
-
|
|
31
|
-
describe('<%= friendlyTestName %>', function() {
|
|
32
|
-
|
|
33
|
-
// TODO: Replace this with your real tests.
|
|
34
|
-
it('works', function() {
|
|
35
|
-
let result = <%= camelizedModuleName %>(42);
|
|
36
|
-
expect(result).to.be.ok;
|
|
37
|
-
});
|
|
38
|
-
});
|
|
39
|
-
<% } %>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { expect } from 'chai';
|
|
2
|
-
|
|
2
|
+
import { describe, it } from 'mocha';
|
|
3
3
|
import { setupRenderingTest } from 'ember-mocha';
|
|
4
4
|
import { render } from '@ember/test-helpers';
|
|
5
5
|
<%= hbsImportStatement %>
|
|
@@ -15,14 +15,4 @@ describe('<%= friendlyTestName %>', function() {
|
|
|
15
15
|
|
|
16
16
|
expect(this.element.textContent.trim()).to.equal('1234');
|
|
17
17
|
});
|
|
18
|
-
})
|
|
19
|
-
import { <%= camelizedModuleName %> } from '<%= dasherizedPackageName %>/helpers/<%= dasherizedModuleName %>';
|
|
20
|
-
|
|
21
|
-
describe('<%= friendlyTestName %>', function() {
|
|
22
|
-
|
|
23
|
-
// TODO: Replace this with your real tests.
|
|
24
|
-
it('works', function() {
|
|
25
|
-
let result = <%= camelizedModuleName %>(42);
|
|
26
|
-
expect(result).to.be.ok;
|
|
27
|
-
});
|
|
28
|
-
});<% } %>
|
|
18
|
+
});
|
package/blueprints/helper-test/qunit-files/__root__/__testType__/__collection__/__name__-test.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import { moduleForComponent, test } from 'ember-qunit';
|
|
2
2
|
import hbs from 'htmlbars-inline-precompile';
|
|
3
3
|
|
|
4
4
|
moduleForComponent('<%= dasherizedModuleName %>', 'helper:<%= dasherizedModuleName %>', {
|
|
@@ -11,16 +11,5 @@ test('it renders', function(assert) {
|
|
|
11
11
|
|
|
12
12
|
this.render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);
|
|
13
13
|
|
|
14
|
-
assert.
|
|
15
|
-
});<% } else if (testType == 'unit') { %>
|
|
16
|
-
import { <%= camelizedModuleName %> } from '<%= dasherizedModulePrefix %>/helpers/<%= dasherizedModuleName %>';
|
|
17
|
-
import { module, test } from 'qunit';
|
|
18
|
-
|
|
19
|
-
module('<%= friendlyTestName %>');
|
|
20
|
-
|
|
21
|
-
// TODO: Replace this with your real tests.
|
|
22
|
-
test('it works', function(assert) {
|
|
23
|
-
let result = <%= camelizedModuleName %>([42]);
|
|
24
|
-
assert.ok(result);
|
|
14
|
+
assert.strictEqual(this.$().text().trim(), '1234');
|
|
25
15
|
});
|
|
26
|
-
<% } %>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import { module, test } from 'qunit';
|
|
2
2
|
import { setupRenderingTest } from 'ember-qunit';
|
|
3
3
|
import { render } from '@ember/test-helpers';
|
|
4
4
|
<%= hbsImportStatement %>
|
|
@@ -14,16 +14,4 @@ module('<%= friendlyTestName %>', function(hooks) {
|
|
|
14
14
|
|
|
15
15
|
assert.dom(this.element).hasText('1234');
|
|
16
16
|
});
|
|
17
|
-
})
|
|
18
|
-
import { module, test } from 'qunit';
|
|
19
|
-
import { setupTest } from 'ember-qunit';
|
|
20
|
-
|
|
21
|
-
module('<%= friendlyTestName %>', function(hooks) {
|
|
22
|
-
setupTest(hooks);
|
|
23
|
-
|
|
24
|
-
// TODO: Replace this with your real tests.
|
|
25
|
-
test('it works', function(assert) {
|
|
26
|
-
let result = <%= camelizedModuleName %>([42]);
|
|
27
|
-
assert.ok(result);
|
|
28
|
-
});
|
|
29
|
-
});<% } %>
|
|
17
|
+
});
|
package/build-metadata.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "4.
|
|
2
|
+
"version": "4.2.0-alpha.1",
|
|
3
3
|
"buildType": "tag",
|
|
4
|
-
"SHA": "
|
|
5
|
-
"assetPath": "/tag/shas/
|
|
4
|
+
"SHA": "944637def23d8fab349f232688b2a2e3889457d8",
|
|
5
|
+
"assetPath": "/tag/shas/944637def23d8fab349f232688b2a2e3889457d8.tgz"
|
|
6
6
|
}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { DEBUG } from '@glimmer/env';
|
|
2
|
-
import { debugToString, _WeakSet, HAS_NATIVE_PROXY
|
|
2
|
+
import { debugToString, _WeakSet, HAS_NATIVE_PROXY } from '@glimmer/util';
|
|
3
3
|
import { valueForRef, createConstRef, createComputeRef, UNDEFINED_REFERENCE } from '@glimmer/reference';
|
|
4
|
-
import { track,
|
|
4
|
+
import { track, createUpdatableTag, untrack } from '@glimmer/validator';
|
|
5
5
|
import { registerDestructor, associateDestroyableChild } from '@glimmer/destroyable';
|
|
6
|
-
import { setOwner } from '@glimmer/owner';
|
|
7
6
|
|
|
8
7
|
const COMPONENT_MANAGERS = new WeakMap();
|
|
9
8
|
const MODIFIER_MANAGERS = new WeakMap();
|
|
@@ -382,16 +381,11 @@ const CAPABILITIES = {
|
|
|
382
381
|
hasSubOwner: false
|
|
383
382
|
};
|
|
384
383
|
function componentCapabilities(managerAPI, options = {}) {
|
|
385
|
-
if (DEBUG && managerAPI !== '3.
|
|
384
|
+
if (DEBUG && managerAPI !== '3.13') {
|
|
386
385
|
throw new Error('Invalid component manager compatibility specified');
|
|
387
386
|
}
|
|
388
387
|
|
|
389
|
-
let updateHook =
|
|
390
|
-
|
|
391
|
-
if (managerAPI === '3.13') {
|
|
392
|
-
updateHook = Boolean(options.updateHook);
|
|
393
|
-
}
|
|
394
|
-
|
|
388
|
+
let updateHook = Boolean(options.updateHook);
|
|
395
389
|
return buildCapabilities({
|
|
396
390
|
asyncLifeCycleCallbacks: Boolean(options.asyncLifecycleCallbacks),
|
|
397
391
|
destructor: Boolean(options.destructor),
|
|
@@ -456,7 +450,7 @@ class CustomComponentManager {
|
|
|
456
450
|
|
|
457
451
|
if (DEBUG && !FROM_CAPABILITIES.has(delegate.capabilities)) {
|
|
458
452
|
// TODO: This error message should make sense in both Ember and Glimmer https://github.com/glimmerjs/glimmer-vm/issues/1200
|
|
459
|
-
throw new Error(`Custom component managers must have a \`capabilities\` property that is the result of calling the \`capabilities('3.
|
|
453
|
+
throw new Error(`Custom component managers must have a \`capabilities\` property that is the result of calling the \`capabilities('3.13')\` (imported via \`import { capabilities } from '@ember/component';\`). Received: \`${JSON.stringify(delegate.capabilities)}\` for: \`${delegate}\``);
|
|
460
454
|
}
|
|
461
455
|
|
|
462
456
|
componentManagerDelegates.set(owner, delegate);
|
|
@@ -468,16 +462,7 @@ class CustomComponentManager {
|
|
|
468
462
|
create(owner, definition, vmArgs) {
|
|
469
463
|
let delegate = this.getDelegateFor(owner);
|
|
470
464
|
let args = argsProxyFor(vmArgs.capture(), 'component');
|
|
471
|
-
let component;
|
|
472
|
-
|
|
473
|
-
if (DEBUG && deprecateMutationsInTrackingTransaction !== undefined) {
|
|
474
|
-
deprecateMutationsInTrackingTransaction(() => {
|
|
475
|
-
component = delegate.createComponent(definition, args);
|
|
476
|
-
});
|
|
477
|
-
} else {
|
|
478
|
-
component = delegate.createComponent(definition, args);
|
|
479
|
-
}
|
|
480
|
-
|
|
465
|
+
let component = delegate.createComponent(definition, args);
|
|
481
466
|
return new CustomComponentState(component, delegate, args);
|
|
482
467
|
}
|
|
483
468
|
|
|
@@ -563,16 +548,12 @@ class CustomComponentState {
|
|
|
563
548
|
}
|
|
564
549
|
|
|
565
550
|
function modifierCapabilities(managerAPI, optionalFeatures = {}) {
|
|
566
|
-
if (DEBUG && managerAPI !== '3.
|
|
551
|
+
if (DEBUG && managerAPI !== '3.22') {
|
|
567
552
|
throw new Error('Invalid modifier manager compatibility specified');
|
|
568
553
|
}
|
|
569
554
|
|
|
570
555
|
return buildCapabilities({
|
|
571
|
-
disableAutoTracking: Boolean(optionalFeatures.disableAutoTracking)
|
|
572
|
-
useArgsProxy: managerAPI === '3.13' ? false : true,
|
|
573
|
-
// This capability is used in Ember, exclusively in resolution mode. See the
|
|
574
|
-
// Ember glimmer resolver for details.
|
|
575
|
-
passFactoryToCreate: managerAPI === '3.13'
|
|
556
|
+
disableAutoTracking: Boolean(optionalFeatures.disableAutoTracking)
|
|
576
557
|
});
|
|
577
558
|
}
|
|
578
559
|
/**
|
|
@@ -620,7 +601,7 @@ class CustomModifierManager {
|
|
|
620
601
|
|
|
621
602
|
if (DEBUG && !FROM_CAPABILITIES.has(delegate.capabilities)) {
|
|
622
603
|
// TODO: This error message should make sense in both Ember and Glimmer https://github.com/glimmerjs/glimmer-vm/issues/1200
|
|
623
|
-
throw new Error(`Custom modifier managers must have a \`capabilities\` property that is the result of calling the \`capabilities('3.
|
|
604
|
+
throw new Error(`Custom modifier managers must have a \`capabilities\` property that is the result of calling the \`capabilities('3.22')\` (imported via \`import { capabilities } from '@ember/modifier';\`). Received: \`${JSON.stringify(delegate.capabilities)}\` for: \`${delegate}\``);
|
|
624
605
|
}
|
|
625
606
|
|
|
626
607
|
componentManagerDelegates.set(owner, delegate);
|
|
@@ -631,67 +612,23 @@ class CustomModifierManager {
|
|
|
631
612
|
|
|
632
613
|
create(owner, element, definition, capturedArgs) {
|
|
633
614
|
let delegate = this.getDelegateFor(owner);
|
|
634
|
-
let
|
|
635
|
-
|
|
636
|
-
passFactoryToCreate
|
|
637
|
-
} = delegate.capabilities;
|
|
638
|
-
let argsProxy = argsProxyFor(capturedArgs, 'modifier');
|
|
639
|
-
let args = useArgsProxy ? argsProxy : reifyArgs(capturedArgs);
|
|
640
|
-
let instance;
|
|
641
|
-
let factoryOrDefinition = definition;
|
|
642
|
-
|
|
643
|
-
if (passFactoryToCreate) {
|
|
644
|
-
// Make a fake factory. While not perfect, this should generally prevent
|
|
645
|
-
// breakage in users of older modifier capabilities.
|
|
646
|
-
factoryOrDefinition = {
|
|
647
|
-
create(args) {
|
|
648
|
-
let params = assign({}, args);
|
|
649
|
-
setOwner(params, owner);
|
|
650
|
-
return definition.create(args);
|
|
651
|
-
},
|
|
652
|
-
|
|
653
|
-
class: definition
|
|
654
|
-
};
|
|
655
|
-
}
|
|
656
|
-
|
|
657
|
-
if (DEBUG && deprecateMutationsInTrackingTransaction !== undefined) {
|
|
658
|
-
deprecateMutationsInTrackingTransaction(() => {
|
|
659
|
-
instance = delegate.createModifier(factoryOrDefinition, args);
|
|
660
|
-
});
|
|
661
|
-
} else {
|
|
662
|
-
instance = delegate.createModifier(factoryOrDefinition, args);
|
|
663
|
-
}
|
|
664
|
-
|
|
615
|
+
let args = argsProxyFor(capturedArgs, 'modifier');
|
|
616
|
+
let instance = delegate.createModifier(definition, args);
|
|
665
617
|
let tag = createUpdatableTag();
|
|
666
618
|
let state;
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
modifier: instance
|
|
675
|
-
};
|
|
676
|
-
} else {
|
|
677
|
-
state = {
|
|
678
|
-
tag,
|
|
679
|
-
element,
|
|
680
|
-
modifier: instance,
|
|
681
|
-
delegate,
|
|
682
|
-
|
|
683
|
-
get args() {
|
|
684
|
-
return reifyArgs(capturedArgs);
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
};
|
|
688
|
-
}
|
|
619
|
+
state = {
|
|
620
|
+
tag,
|
|
621
|
+
element,
|
|
622
|
+
delegate,
|
|
623
|
+
args,
|
|
624
|
+
modifier: instance
|
|
625
|
+
};
|
|
689
626
|
|
|
690
627
|
if (DEBUG) {
|
|
691
628
|
state.debugName = typeof definition === 'function' ? definition.name : definition.toString();
|
|
692
629
|
}
|
|
693
630
|
|
|
694
|
-
registerDestructor(state, () => delegate.destroyModifier(instance,
|
|
631
|
+
registerDestructor(state, () => delegate.destroyModifier(instance, args));
|
|
695
632
|
return state;
|
|
696
633
|
}
|
|
697
634
|
|
|
@@ -745,22 +682,6 @@ class CustomModifierManager {
|
|
|
745
682
|
}
|
|
746
683
|
|
|
747
684
|
}
|
|
748
|
-
function reifyArgs({
|
|
749
|
-
named,
|
|
750
|
-
positional
|
|
751
|
-
}) {
|
|
752
|
-
let reifiedNamed = dict();
|
|
753
|
-
|
|
754
|
-
for (let key in named) {
|
|
755
|
-
reifiedNamed[key] = valueForRef(named[key]);
|
|
756
|
-
}
|
|
757
|
-
|
|
758
|
-
let reifiedPositional = positional.map(valueForRef);
|
|
759
|
-
return {
|
|
760
|
-
named: reifiedNamed,
|
|
761
|
-
positional: reifiedPositional
|
|
762
|
-
};
|
|
763
|
-
}
|
|
764
685
|
|
|
765
686
|
function helperCapabilities(managerAPI, options = {}) {
|
|
766
687
|
if (DEBUG && managerAPI !== '3.23') {
|