@types/ember-qunit
Advanced tools
Comparing version 2.2.3 to 2.2.4
@@ -10,111 +10,105 @@ // Type definitions for ember-qunit 2.2 | ||
declare module 'ember-qunit' { | ||
import Ember from 'ember'; | ||
import { ModuleCallbacks } from "ember-test-helpers"; | ||
import Ember from 'ember'; | ||
import { ModuleCallbacks, TestContext } from "ember-test-helpers"; | ||
interface QUnitModuleCallbacks extends ModuleCallbacks, Hooks { | ||
beforeSetup?(assert: Assert): void; | ||
setup?(assert: Assert): void; | ||
teardown?(assert: Assert): void; | ||
afterTeardown?(assert: Assert): void; | ||
} | ||
interface QUnitModuleCallbacks extends ModuleCallbacks, Hooks { | ||
beforeSetup?(assert: Assert): void; | ||
setup?(assert: Assert): void; | ||
teardown?(assert: Assert): void; | ||
afterTeardown?(assert: Assert): void; | ||
} | ||
/** | ||
* @param fullName The full name of the unit, ie controller:application, route:index. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleFor(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleFor(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* @param fullName The full name of the unit, ie controller:application, route:index. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleFor(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleFor(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* @param fullName the short name of the component that you'd use in a template, ie x-foo, ic-tabs, etc. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleForComponent(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleForComponent(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* @param fullName the short name of the component that you'd use in a template, ie x-foo, ic-tabs, etc. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleForComponent(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleForComponent(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* @param fullName the short name of the model you'd use in store operations ie user, assignmentGroup, etc. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleForModel(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleForModel(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* @param fullName the short name of the model you'd use in store operations ie user, assignmentGroup, etc. | ||
* @param description The description of the module | ||
*/ | ||
export function moduleForModel(fullName: string, description: string, callbacks?: QUnitModuleCallbacks): void; | ||
export function moduleForModel(fullName: string, callbacks?: QUnitModuleCallbacks): void; | ||
/** | ||
* Sets a Resolver globally which will be used to look up objects from each test's container. | ||
*/ | ||
export function setResolver(resolver: Ember.Resolver): void; | ||
/** | ||
* Sets a Resolver globally which will be used to look up objects from each test's container. | ||
*/ | ||
export function setResolver(resolver: Ember.Resolver): void; | ||
export class QUnitAdapter extends Ember.Test.Adapter {} | ||
export class QUnitAdapter extends Ember.Test.Adapter {} | ||
export { module, test, skip, only, todo } from 'qunit'; | ||
} | ||
export { module, test, skip, only, todo } from 'qunit'; | ||
declare module 'qunit' { | ||
import { TestContext } from "ember-test-helpers"; | ||
declare global { | ||
interface QUnit { | ||
/** | ||
* Add a test to run. | ||
* | ||
* Add a test to run using `QUnit.test()`. | ||
* | ||
* The `assert` argument to the callback contains all of QUnit's assertion | ||
* methods. Use this argument to call your test assertions. | ||
* | ||
* `QUnit.test()` can automatically handle the asynchronous resolution of a | ||
* Promise on your behalf if you return a thenable Promise as the result of | ||
* your callback function. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
test(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
export const module: typeof QUnit.module; | ||
/** | ||
* Adds a test to exclusively run, preventing all other tests from running. | ||
* | ||
* Use this method to focus your test suite on a specific test. QUnit.only | ||
* will cause any other tests in your suite to be ignored. | ||
* | ||
* Note, that if more than one QUnit.only is present only the first instance | ||
* will run. | ||
* | ||
* This is an alternative to filtering tests to run in the HTML reporter. It | ||
* is especially useful when you use a console reporter or in a codebase | ||
* with a large set of long running tests. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
only(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
/** | ||
* Add a test to run. | ||
* | ||
* Add a test to run using `QUnit.test()`. | ||
* | ||
* The `assert` argument to the callback contains all of QUnit's assertion | ||
* methods. Use this argument to call your test assertions. | ||
* | ||
* `QUnit.test()` can automatically handle the asynchronous resolution of a | ||
* Promise on your behalf if you return a thenable Promise as the result of | ||
* your callback function. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
export function test(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
/** | ||
* Use this method to test a unit of code which is still under development (in a “todo” state). | ||
* The test will pass as long as one failing assertion is present. | ||
* | ||
* If all assertions pass, then the test will fail signaling that `QUnit.todo` should | ||
* be replaced by `QUnit.test`. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
todo(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
/** | ||
* Adds a test to exclusively run, preventing all other tests from running. | ||
* | ||
* Use this method to focus your test suite on a specific test. QUnit.only | ||
* will cause any other tests in your suite to be ignored. | ||
* | ||
* Note, that if more than one QUnit.only is present only the first instance | ||
* will run. | ||
* | ||
* This is an alternative to filtering tests to run in the HTML reporter. It | ||
* is especially useful when you use a console reporter or in a codebase | ||
* with a large set of long running tests. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
export function only(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
/** | ||
* Use this method to test a unit of code which is still under development (in a “todo” state). | ||
* The test will pass as long as one failing assertion is present. | ||
* | ||
* If all assertions pass, then the test will fail signaling that `QUnit.todo` should | ||
* be replaced by `QUnit.test`. | ||
* | ||
* @param name Title of unit being tested | ||
* @param callback Function to close over assertions | ||
*/ | ||
export function todo(name: string, callback: (this: TestContext, assert: Assert) => void): void; | ||
/** | ||
* Adds a test like object to be skipped. | ||
* | ||
* Use this method to replace QUnit.test() instead of commenting out entire | ||
* tests. | ||
* | ||
* This test's prototype will be listed on the suite as a skipped test, | ||
* ignoring the callback argument and the respective global and module's | ||
* hooks. | ||
* | ||
* @param Title of unit being tested | ||
*/ | ||
export const skip: typeof QUnit.skip; | ||
export default QUnit; | ||
/** | ||
* Adds a test like object to be skipped. | ||
* | ||
* Use this method to replace QUnit.test() instead of commenting out entire | ||
* tests. | ||
* | ||
* This test's prototype will be listed on the suite as a skipped test, | ||
* ignoring the callback argument and the respective global and module's | ||
* hooks. | ||
* | ||
* @param Title of unit being tested | ||
*/ | ||
skip: typeof QUnit.skip; | ||
} | ||
} |
{ | ||
"name": "@types/ember-qunit", | ||
"version": "2.2.3", | ||
"version": "2.2.4", | ||
"description": "TypeScript definitions for ember-qunit", | ||
@@ -28,6 +28,7 @@ "license": "MIT", | ||
"@types/ember": "^2", | ||
"@types/ember-test-helpers": "^0" | ||
"@types/ember-test-helpers": "^0", | ||
"@types/qunit": "*" | ||
}, | ||
"typesPublisherContentHash": "2eda96b67580ae4ffa3c5b21250e484f821a5b42f81bef32994913b5ce0dd29e", | ||
"typesPublisherContentHash": "0ddd20711e91157138d23e9f3e88d1792591c063bd514bdc2f7b4b18bddc0dec", | ||
"typeScriptVersion": "3.7" | ||
} |
@@ -11,4 +11,4 @@ # Installation | ||
### Additional Details | ||
* Last updated: Wed, 10 Jun 2020 17:07:09 GMT | ||
* Dependencies: [@types/ember](https://npmjs.com/package/@types/ember), [@types/ember-test-helpers](https://npmjs.com/package/@types/ember-test-helpers) | ||
* Last updated: Tue, 22 Sep 2020 21:02:29 GMT | ||
* Dependencies: [@types/ember](https://npmjs.com/package/@types/ember), [@types/ember-test-helpers](https://npmjs.com/package/@types/ember-test-helpers), [@types/qunit](https://npmjs.com/package/@types/qunit) | ||
* Global values: none | ||
@@ -15,0 +15,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
7487
3
100
+ Added@types/qunit@*
+ Added@types/qunit@2.19.12(transitive)