Skip to content

Commit

Permalink
feat(core): add support for electron-nightly
Browse files Browse the repository at this point in the history
  • Loading branch information
malept committed Jan 8, 2019
1 parent 21b76bb commit 35077a9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/api/core/src/util/electron-version.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const d = debug('electron-forge:electron-version');
const electronPackageNames = [
'electron-prebuilt-compile',
'electron-prebuilt',
'electron-nightly',
'electron',
];

Expand Down
7 changes: 7 additions & 0 deletions packages/api/core/test/fast/electron-version_spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,13 @@ describe('getElectronVersion', () => {
expect(getElectronVersion(packageJSON)).to.be.equal('1.0.0');
});

it('works with electron-nightly', () => {
const packageJSON = {
devDependencies: { 'electron-nightly': '5.0.0-nightly.20190107' },
};
expect(getElectronVersion(packageJSON)).to.be.equal('5.0.0-nightly.20190107');
});

it('works with electron', () => {
const packageJSON = {
devDependencies: { electron: '1.0.0' },
Expand Down

0 comments on commit 35077a9

Please sign in to comment.