Skip to content

Commit

Permalink
Merge pull request #19 from gabrielboliveira/expose-consts
Browse files Browse the repository at this point in the history
Expose framerate as consts
  • Loading branch information
gabrielboliveira authored Sep 5, 2019
2 parents 988b725 + 08de8e4 commit 8e5dcbf
Show file tree
Hide file tree
Showing 5 changed files with 82 additions and 255 deletions.
9 changes: 0 additions & 9 deletions now.json

This file was deleted.

7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,13 @@
"@babel/plugin-proposal-class-properties": "^7.5.5",
"@babel/preset-env": "^7.5.5",
"@babel/register": "^7.5.5",
"babel-eslint": "^10.0.2",
"babel-eslint": "^10.0.3",
"chai": "^4.2.0",
"codecov": "^3.5.0",
"eslint": "^6.1.0",
"laravel-mix": "^4.1.2",
"eslint": "^6.3.0",
"laravel-mix": "4.1.2",
"mocha": "^6.2.0",
"nyc": "^14.1.1",
"serve": "^11.1.0",
"vue-template-compiler": "^2.6.10"
},
"dependencies": {}
Expand Down
1 change: 1 addition & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ SMPTE.frameCountFromTimecode = function (timecode, fr = SMPTE.defaults.frameRate
return _fc;
};

SMPTE.consts = Object.assign({}, FrameRate);
SMPTE.defaults = defaults;
SMPTE.supportedFrameRates = supportedFRs;

Expand Down
10 changes: 10 additions & 0 deletions test/unit/timecode.static.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,16 @@ describe('SMPTE', function () {
});
});

describe('.consts', function () {
it('should expose an object', function () {
expect(SMPTE.consts).to.be.an('object');
});

it('should have all FrameRates', function () {
expect(SMPTE.consts).to.include(FrameRate);
});
});

describe('.isValidTimecode()', function () {
const isValidTimecode = SMPTE.isValidTimecode;

Expand Down
Loading

0 comments on commit 8e5dcbf

Please sign in to comment.