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

[Raja] testing docs upgrade to latest ember #671

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 8 additions & 11 deletions addon/validators/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -434,16 +434,14 @@ export default Base;
* ```javascript
* // tests/unit/validators/unique-username-test.js
*
* import Ember from 'ember';
* import { moduleFor, test } from 'ember-qunit';
*
* moduleFor('validator:unique-username', 'Unit | Validator | unique-username', {
* needs: ['validator:messages']
* });
* import { module, test } from "qunit";
*
* test('it works', function(assert) {
* const validator = this.subject();
* assert.ok(validator);
* module("Unit | Validator | unique-username", function() {
* test('it works', function(assert) {
* assert.expect(1);
* const validator = this.owner.lookup("validator:unique-username");
* assert.ok(validator);
* })
* });
* ```
*
Expand All @@ -452,8 +450,7 @@ export default Base;
* ```javascript
* test('username is unique', function(assert) {
* assert.expect(1);
*
* let validator = this.subject();
* let validator = this.owner.lookup("validator:unique-username");
* let done = assert.async();
*
* validator.validate('johndoe42').then((message) => {
Expand Down