New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

chai-isodatetime

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chai-isodatetime

Plugin for Chai to use .toISODate() for date comparisons

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
decreased by-42.86%
Maintainers
1
Weekly downloads
 
Created
Source

chai-isodatetime

NPM version

Plugin for Chai to use .toISODate() for date comparisons

Usage

import * as chai from 'chai';
import { isoDateTime } from 'chai-isodatetime';
chai.use(isoDateTime);

Assertions

  • equalDate - Checks if both dates equal each other using .toISODate() for comparison
const date1 = new Date(2013, 4, 30, 16, 5);
const date2 = new Date(2013, 4, 30, 17);

date1.should.equalDate(date2);
expect(date1).to.equalDate(date2)
assert.equalDate(date1, date2)

Acknowledgement

Thanks to chai-datetime for getting me most of the way there!

License

MIT

Keywords

FAQs

Package last updated on 29 Jan 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc