f6db0640a6
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@ember/test-helpers](https://togithub.com/emberjs/ember-test-helpers) | [`2.8.1` -> `2.9.3`](https://renovatebot.com/diffs/npm/@ember%2ftest-helpers/2.8.1/2.9.3) | [![age](https://badges.renovateapi.com/packages/npm/@ember%2ftest-helpers/2.9.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/npm/@ember%2ftest-helpers/2.9.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/npm/@ember%2ftest-helpers/2.9.3/compatibility-slim/2.8.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/npm/@ember%2ftest-helpers/2.9.3/confidence-slim/2.8.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>emberjs/ember-test-helpers</summary> ### [`v2.9.3`](https://togithub.com/emberjs/ember-test-helpers/releases/tag/v2.9.3): Release 2.9.3 [Compare Source](https://togithub.com/emberjs/ember-test-helpers/compare/v2.9.2...v2.9.3) ##### 🐛 Bug Fix - [#​1305](https://togithub.com/emberjs/ember-test-helpers/pull/1305) \[backport] Avoid unnecessary dependencies on `@glimmer` types ([@​dfreeman](https://togithub.com/dfreeman)) ##### Committers: 1 - Dan Freeman ([@​dfreeman](https://togithub.com/dfreeman)) ### [`v2.9.2`](https://togithub.com/emberjs/ember-test-helpers/releases/tag/v2.9.2): Release 2.9.2 [Compare Source](https://togithub.com/emberjs/ember-test-helpers/compare/v2.9.1...v2.9.2) ##### 🐛 Bug Fix - [#​1302](https://togithub.com/emberjs/ember-test-helpers/pull/1302) \[backport] Remove the index signature from `TestContext` ([@​chriskrycho](https://togithub.com/chriskrycho)) - Backporting [#​1301](https://togithub.com/emberjs/ember-test-helpers/pull/1301) Remove the index signature from `TestContext` ([@​dfreeman](https://togithub.com/dfreeman)) - [#​1303](https://togithub.com/emberjs/ember-test-helpers/pull/1303) `TestContext.resumeTest()` returns `void`, not `Promise<void>` ([@​chriskrycho](https://togithub.com/chriskrycho)) ##### Committers: 1 - Chris Krycho ([@​chriskrycho](https://togithub.com/chriskrycho)) - Dan Freeman ([@​dfreeman](https://togithub.com/dfreeman)) ### [`v2.9.1`](https://togithub.com/emberjs/ember-test-helpers/blob/HEAD/CHANGELOG.md#v291-2022-12-16) [Compare Source](https://togithub.com/emberjs/ember-test-helpers/compare/v2.9.0...v2.9.1) ***Note:** these were all back-ported from master since they could go out on 2.9. This will be the last 2.9 release unless there are critical bug fixes here!* ##### 🐛 Bug Fix - Let ESLint have its way about docstring location ([`a8fac83`](https://togithub.com/emberjs/ember-test-helpers/commit/a8fac83)) - DOC: API: add render helper examples ([`f476a20`](https://togithub.com/emberjs/ember-test-helpers/commit/f476a20)) - Tweak TS style for indexing multiple types (for getElement) ([`f01ad9f`](https://togithub.com/emberjs/ember-test-helpers/commit/f01ad9f)) - Use export type for RenderingTestContext ([`2dc5077`](https://togithub.com/emberjs/ember-test-helpers/commit/2dc5077)) - Tweak TS style for indexing multiple types ([`3214483`](https://togithub.com/emberjs/ember-test-helpers/commit/3214483)) - Address PR feedback ([`5e87a54`](https://togithub.com/emberjs/ember-test-helpers/commit/5e87a54)) - DOC: API: add DOM query helper examples ([`83b7f5f`](https://togithub.com/emberjs/ember-test-helpers/commit/83b7f5f)) - Export type for Target ([`335019d`](https://togithub.com/emberjs/ember-test-helpers/commit/335019d)) - Upgrade expect-type and fix issues the new version reveals ([`bae5e33`](https://togithub.com/emberjs/ember-test-helpers/commit/bae5e33)) - Correctly handle special char keyCodes with Shift ([`d537923`](https://togithub.com/emberjs/ember-test-helpers/commit/d537923)) - Add tab type test ([`64f40d5`](https://togithub.com/emberjs/ember-test-helpers/commit/64f40d5)) - Generate documentation ([`939f29f`](https://togithub.com/emberjs/ember-test-helpers/commit/939f29f)) - Ensure types reflect optional-ness of tab options ([`95285cc`](https://togithub.com/emberjs/ember-test-helpers/commit/95285cc)) - Fix typesVersions config again ([`53fa899`](https://togithub.com/emberjs/ember-test-helpers/commit/53fa899)) - Clean up public-types after pack ([`b9dcbca`](https://togithub.com/emberjs/ember-test-helpers/commit/b9dcbca)) ### [`v2.9.0`](https://togithub.com/emberjs/ember-test-helpers/blob/HEAD/CHANGELOG.md#v290-2022-12-14) [Compare Source](https://togithub.com/emberjs/ember-test-helpers/compare/v2.8.1...v2.9.0) ##### 🚀 Enhancement - [#​1269](https://togithub.com/emberjs/ember-test-helpers/pull/1269) Re-export hasEmberVersion (and its type) from [@​ember/test-helpers](https://togithub.com/ember/test-helpers) ([@​gitKrystan](https://togithub.com/gitKrystan)) - [#​1278](https://togithub.com/emberjs/ember-test-helpers/pull/1278) perf: Remove excessive destroy call ([@​runspired](https://togithub.com/runspired)) - [#​1234](https://togithub.com/emberjs/ember-test-helpers/pull/1234) Introduce public TypeScript support ([@​chriskrycho](https://togithub.com/chriskrycho)) ##### 🐛 Bug Fix - [#​1277](https://togithub.com/emberjs/ember-test-helpers/pull/1277) Actually publish .d.ts ([@​gitKrystan](https://togithub.com/gitKrystan)) - [#​1270](https://togithub.com/emberjs/ember-test-helpers/pull/1270) Fix typesVersions path ([@​gitKrystan](https://togithub.com/gitKrystan)) - [#​1233](https://togithub.com/emberjs/ember-test-helpers/pull/1233) Add more keyCode mappings ([@​CvX](https://togithub.com/CvX)) ##### 📝 Documentation - [#​1259](https://togithub.com/emberjs/ember-test-helpers/pull/1259) DOCS: API: publish docs for tab ([@​geneukum](https://togithub.com/geneukum)) ##### Committers: 5 - Chris Krycho ([@​chriskrycho](https://togithub.com/chriskrycho)) - Chris Thoburn ([@​runspired](https://togithub.com/runspired)) - Geordan Neukum ([@​geneukum](https://togithub.com/geneukum)) - Jarek Radosz ([@​CvX](https://togithub.com/CvX)) - Krystan HuffMenne ([@​gitKrystan](https://togithub.com/gitKrystan)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - "every weekday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/TryGhost/Ghost). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC41NC4yIiwidXBkYXRlZEluVmVyIjoiMzQuNjYuMSJ9--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> |
||
---|---|---|
.. | ||
app | ||
config | ||
lib | ||
mirage | ||
public/assets | ||
tests | ||
.editorconfig | ||
.ember-cli | ||
.eslintignore | ||
.eslintrc.js | ||
.gitignore | ||
.lint-todo | ||
.lint-todorc.js | ||
.template-lintrc.js | ||
.watchmanconfig | ||
ember-cli-build.js | ||
ember-cli-update.json | ||
package.json | ||
README.md | ||
testem.js |
Ghost-Admin
This is the home of the Ember.js-based Admin app that ships with Ghost.
Running tests
Build and run tests once:
TZ=UTC yarn test
Note the TZ=UTC
environment variable which is currently required to get tests working if your system timezone doesn't match UTC.
If you are serving the admin app (e.g., when running yarn serve
, or when running yarn dev
in the main Ghost project), you can also run the tests in your browser by going to http://localhost:4200/tests.
This has the additional benefit that you can use await this.pauseTest()
in your tests to temporarily pause tests (best to also add this.timeout(0);
to avoid timeouts). This allows you to inspect the DOM in your browser to debug tests. You can resume tests by running resumeTest()
in your browser console.
Writing tests
When writing tests and not using the http://localhost:4200/tests
browser tests, it can be easier to have a separate watching build that builds the project for the test environment (this drastically reduces the time you have to wait when running tests):
yarn build --environment=test -w -o="dist-test"
After that, you can easily run tests locally:
Run all tests:
TZ=UTC yarn test 1 --path="dist-test"
To have a cleaner output:
TZ=UTC yarn test 1 --reporter dot --path="dist-test"
This shows a dot (.
) for every successful test, and F
for every failed test. At the end, it will only show the output of the failed tests.
To run a specific test file:
TZ=UTC yarn test 1 --reporter dot --path="dist-test" -mp=tests/acceptance/settings/newsletters-test.js
Hint: you can easily copy the path of a test in VSCode by right clicking on the test file and choosing Copy Relative Path
.
To have a full list of the available options, run
ember exam --help
Copyright & License
Copyright (c) 2013-2022 Ghost Foundation - Released under the MIT license. Ghost and the Ghost Logo are trademarks of Ghost Foundation Ltd. Please see our trademark policy for info on acceptable usage.