Skip to content

PR to update chai.d.ts to latest chai ([email protected]) - #5081

Merged
vvakame merged 1 commit into
DefinitelyTyped:masterfrom
olivr70:master
Sep 8, 2015
Merged

vvakame merged 1 commit into
DefinitelyTyped:masterfrom
olivr70:master

Conversation

@olivr70

@olivr70 olivr70 commented Jul 26, 2015

Copy link
Copy Markdown
Contributor

Hi everyone,

Chai has changed a lot lately, and many intersting features were missing.

Support added for : all, any, fail, ownPropertyDescriptor, frozen, sealed, extensible, NaN, isAbove, isBelow, sameDeepMembers
Updated some assertions : keys(Object), matches
Added new aliases : contains, includes, isOk, isNotOk

chai-tests.ts was updated accordingly.

I also added a subfolder tests. It contains effective mocha tests.

To run those tests :

  1. run setup.sh once (it npm installs mocha and chai)
  2. run run.sh to run the tests (it compiles the TS and invokes mocha)

The problem is that this directory is reported as "typing without test" and the npm test report marks it as failed. 2 options there :

  • just discard this directory (not nécessary for users of chai.d.ts)
    • I think it is a pity not to share this testing code
    • I think dt should not consider a subdirectory a a typing
  • make a little change to dt to ignore subfolders

Hope this helps

@vvakame

vvakame commented Jul 28, 2015

Copy link
Copy Markdown
Member

chai/chai.d.ts

to authors(@jedmao @Bartvds @AGBrown). could you review this PR?
👍 or 👎?

check list

  • pass the Travic-CI test?

@jednano

jednano commented Jul 28, 2015

Copy link
Copy Markdown
Contributor

Excellent work! But you need to rename the existing chai.d.ts file to chai-2.0.0.d.ts. See http://definitelytyped.org/guides/contributing.html#version

Then, squash your changes and I'll give you a thumbs up.

@olivr70

olivr70 commented Sep 3, 2015

Copy link
Copy Markdown
Contributor Author

Done. Sorry for the delay.

@jednano

jednano commented Sep 3, 2015

Copy link
Copy Markdown
Contributor

Sorry, @olivr70, but can we also preserve the 2.0 tests? You can see https://github.com/borisyankov/DefinitelyTyped/tree/master/jasmine for an example of how it's organized. Sorry I didn't mention the tests before.

vvakame added a commit that referenced this pull request Sep 8, 2015
PR to update chai.d.ts to latest chai ([email protected])
@vvakame
vvakame merged commit 33bd579 into DefinitelyTyped:master Sep 8, 2015
@vvakame

vvakame commented Sep 8, 2015

Copy link
Copy Markdown
Member

@jedmao thanks! I think we should not kept old version definition.
@olivr70 thanks mate!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants