UNPKG

@angular-package/testing

Version:

Jasmine unit testing wrapper with additional custom testing features.

1 lines 967 B
import{TestingCore}from"../testing-core.abstract";import{TestingDescribe}from"../testing-describe.class";import{TestingExpectation}from"../testing-expectation.class";import{TextualExpectation}from"../textual-expectation.abstract";import{TestingIt}from"../testing-it.class";import{TestingItToHaveBeen}from"./testing-it-to-have-been.class";export class TestingItToHave extends TestingCore{get been(){return this.#t}#t;constructor(t,e,s,i=[!0,!1],n=new TestingDescribe(t,s?.describe,i),o=new TestingIt(e,s?.it,i),a=new TestingExpectation){super(t,e,s,i,n,o,a),this.#t=new TestingItToHaveBeen(t,e,s,i,n,o,a)}class(t,e,s=TextualExpectation.toHaveClass,i,n){return this.it(s,(()=>super.expect.to.have.class(t,e,i)),n),this}size(t,e,s=TextualExpectation.toHaveSize,i,n){return this.it(s,(()=>super.expect.to.have.size(t,e,i)),n),this}spyInteractions(t,e=TextualExpectation.toHaveSpyInteractions,s,i){return this.it(e,(()=>super.expect.to.have.spyInteractions(t,s)),i),this}}