Skip to content

Commit

Permalink
test: improve test labeling
Browse files Browse the repository at this point in the history
  • Loading branch information
maxjeffos committed Aug 9, 2021
1 parent ec9e48f commit bb1d447
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions test/jest/acceptance/analytics.spec.ts
Expand Up @@ -36,8 +36,7 @@ describe('analytics module', () => {
});
});

// test for `snyk test` with a project that has no vulns
it('sends correct analytics data for `snyk test` command', async () => {
it('sends analytics for `snyk test` with no vulns found', async () => {
const project = await createProject('../acceptance/workspaces/npm-package');
const { code } = await runSnykCLI('test', {
cwd: project.path(),
Expand Down Expand Up @@ -101,8 +100,7 @@ describe('analytics module', () => {
});
});

// test for `snyk test` when vulns are found
it('sends correct analytics data for `snyk test` command', async () => {
it('sends analytics for `snyk test` with vulns found', async () => {
const testDepGraphResult = JSON.parse(
fs.readFileSync(
'test/fixtures/npm/with-vulnerable-lodash-dep/test-dep-graph-result.json',
Expand Down Expand Up @@ -184,7 +182,6 @@ describe('analytics module', () => {
});
});

// test for a bad command
it('sends correct analytics data a bad command', async () => {
const project = await createProject('../acceptance/workspaces/npm-package');
const { code } = await runSnykCLI('random-nonsense-command --some-option', {
Expand Down Expand Up @@ -248,8 +245,7 @@ describe('analytics module', () => {
});
});

// no command, i.e. user enters just `snyk`
it('sends correct analytics data a bad command', async () => {
it('sends analytics data a bad command', async () => {
const project = await createProject('../acceptance/workspaces/npm-package');
const { code } = await runSnykCLI('', {
cwd: project.path(),
Expand Down

0 comments on commit bb1d447

Please sign in to comment.