Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separated docs and test apps #165

Merged
merged 16 commits into from
Mar 8, 2023
Merged

Separated docs and test apps #165

merged 16 commits into from
Mar 8, 2023

Conversation

ijlee2
Copy link
Owner

@ijlee2 ijlee2 commented Mar 8, 2023

Background

Since v1.0.0, the test-app for ember-container-query has served as a documentation app. As a result, whether the addon itself is compatible with the beta and canary versions of Ember as well as Embroider (according to ember-try) has depended on whether the documentation app is compatible with them.

What changed?

I created a package called docs-app, which runs on the latest version of Ember and the strictest settings from Embroider. The application tests (e.g. Percy snapshots), in particular, document what end-developers can expect to see from ember-container-query.

The test-app now contains the rendering tests for the <ContainerQuery> component, the 3 helpers, and the modifier. These tests are run under various ember-try scenarios. Note that ember-canary and embroider-optimized are now enabled.

@ijlee2 ijlee2 added the enhance: documentation Issue asks for better documentation (e.g. README, code, tests) label Mar 8, 2023
@ijlee2 ijlee2 force-pushed the separate-docs-and-test-apps branch from fd96ea5 to 02e6c10 Compare March 8, 2023 13:39
@ijlee2 ijlee2 force-pushed the separate-docs-and-test-apps branch from 02e6c10 to 9420705 Compare March 8, 2023 13:52
@ijlee2 ijlee2 marked this pull request as ready for review March 8, 2023 13:59
test-port: 7364
- device: 'w3-h3'
test-port: 7365
- 'embroider-optimized'
Copy link
Owner Author

@ijlee2 ijlee2 Mar 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Previously, enabling embroider-optimized was not possible because the documentation app uses ember-css-modules. (In other words, the addon itself could always have passed embroider-optimized.)

@@ -1,6 +1,6 @@
import { registerDestructor } from '@ember/destroyable';
import { action } from '@ember/object';
import { inject as service } from '@ember/service';
import { service } from '@ember/service';
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Previously, we couldn't use the new syntax (introduced in Ember 4.1) because of the 3.28 scenario.

Comment on lines +14 to +17
'@ember/test-helpers': '2.7.0',
'@types/ember__test-helpers': '2.8.3',
'@types/ember-qunit': '6.1.1',
'ember-qunit': '6.0.0',
Copy link
Owner Author

@ijlee2 ijlee2 Mar 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Temporary solution to emberjs/ember-test-helpers#1232

@ijlee2 ijlee2 mentioned this pull request Mar 8, 2023
8 tasks
@ijlee2 ijlee2 merged commit 73bc0ea into main Mar 8, 2023
@ijlee2 ijlee2 deleted the separate-docs-and-test-apps branch March 8, 2023 14:19
Comment on lines +30 to +31
staticAddonTrees: false, // due to ember-css-modules
staticComponents: false, // due to ember-css-modules
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO

If no further development to make ember-css-modules compatible with Embroider happens, consider removing the addon.

https://github.com/evoactivity/ember-modern-css#ember-modern-css

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhance: documentation Issue asks for better documentation (e.g. README, code, tests)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant