12fromto24hours
Advanced tools
Comparing version 0.0.0 to 1.0.0
@@ -10,3 +10,3 @@ // | ||
*/ | ||
module.exports = function Switch12FromTo24Hours (time) { | ||
module.exports = function _12FromTo24Hours (time) { | ||
let hours, minutes, suffix, result, | ||
@@ -13,0 +13,0 @@ _24HourPattern = /^(0[0-9]|1[0-9]|2[0-3]):[0-5][0-9]$/, |
{ | ||
"name": "12fromto24hours", | ||
"version": "0.0.0", | ||
"version": "1.0.0", | ||
"description": " Switch between 24 and 12 hours made easy .. ", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -1,4 +0,4 @@ | ||
# Switch 12 From To 24 Hours | ||
# 12 From To 24 Hours | ||
[![Build Status](https://travis-ci.org/3imed-jaberi/switch-12-from-to-24-hours.svg?branch=master)](https://travis-ci.org/3imed-jaberi/switch-12-from-to-24-hours) [![Coverage Status](https://coveralls.io/repos/github/3imed-jaberi/switch-12-from-to-24-hours/badge.svg?branch=master)](https://coveralls.io/github/3imed-jaberi/switch-12-from-to-24-hours?branch=master) | ||
[![Build Status](https://travis-ci.org/3imed-jaberi/12-from-to-24-hours.svg?branch=master)](https://travis-ci.org/3imed-jaberi/12-from-to-24-hours) [![Coverage Status](https://coveralls.io/repos/github/3imed-jaberi/12-from-to-24-hours/badge.svg?branch=master)](https://coveralls.io/github/3imed-jaberi/12-from-to-24-hours?branch=master) | ||
@@ -13,3 +13,3 @@ ### Switch between 24 and 12 hours made easy .. | ||
```bash | ||
$ npm install switch-12-from-to-24-hours | ||
$ npm install 12fromto24hours | ||
``` | ||
@@ -19,3 +19,3 @@ | ||
```bash | ||
$ yarn add switch-12-from-to-24-hours | ||
$ yarn add 12fromto24hours | ||
``` | ||
@@ -30,3 +30,3 @@ | ||
const _12FromTo24Hours = require('switch-12-from-to-24-hours'); | ||
const _12FromTo24Hours = require('12fromto24hours'); | ||
@@ -33,0 +33,0 @@ // From 12 to 24 .. |
const { expect } = require('chai'); | ||
const { __resolve, __reject } = require('./_data.json'); | ||
const Switch12FromTo24Hours = require('..'); | ||
const _12FromTo24Hours = require('..'); | ||
@@ -9,9 +9,9 @@ | ||
it ('Check All Success Resulat ✔️', () => { | ||
__resolve.map(({ _24Time, _12Time }) => { expect(Switch12FromTo24Hours(_24Time)).to.equal(_12Time) }); | ||
__resolve.map(({ _24Time, _12Time }) => { expect(_12FromTo24Hours(_24Time)).to.equal(_12Time) }); | ||
}); | ||
it ('Check All Failed Resulat ❌', () => { | ||
__reject.map(({ _24Time, _12Time }) => { expect(() => Switch12FromTo24Hours(_24Time)).to.throw(new Error(_12Time).message) }); | ||
__reject.map(({ _24Time, _12Time }) => { expect(() => _12FromTo24Hours(_24Time)).to.throw(new Error(_12Time).message) }); | ||
}); | ||
}); |
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
0
10798