Skip to content

Commit

Permalink
fix(testing): fix generating cypress-project with no project specified
Browse files Browse the repository at this point in the history
  • Loading branch information
devinshoemaker committed May 8, 2020
1 parent 680541b commit 618c642
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
Expand Up @@ -222,5 +222,20 @@ describe('schematic:cypress-project', () => {
);
});
});

describe('--project', () => {
describe('none', () => {
it('should not add any implicit dependencies', async () => {
const tree = await runSchematic(
'cypress-project',
{ name: 'my-app-e2e' },
appTree
);

const nxJson = readJsonInTree(tree, 'nx.json');
expect(nxJson.projects['my-app-e2e']).toBeFalsy();
});
});
});
});
});
Expand Up @@ -111,7 +111,7 @@ export default function (options: CypressProjectSchema): Rule {
}),
generateFiles(options),
updateWorkspaceJson(options),
updateNxJson(options),
options.project ? updateNxJson(options) : noop(),
]);
}

Expand Down

0 comments on commit 618c642

Please sign in to comment.