Skip to content

Commit

Permalink
pretty
Browse files Browse the repository at this point in the history
  • Loading branch information
jetersen committed Jan 8, 2021
1 parent e34ff90 commit c262250
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions __tests__/labeler.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ const cases = [
]
];

const orginalGitHubRepo = process.env.GITHUB_REPOSITORY
const orginalGitHubRepo = process.env.GITHUB_REPOSITORY;

describe('run', () => {
beforeAll(() => {
Expand Down Expand Up @@ -155,7 +155,7 @@ describe('run', () => {
skipDelete: true,
dryRun: true,
exclude: []
}
};
nock('https://api.github.com').get('/repos/crazy-max/ghaction-github-labeler/labels').reply(200, labelsFixture());

nock('https://api.github.com')
Expand All @@ -168,10 +168,10 @@ describe('run', () => {

const labeler = new Labeler(input);
const fileLabels = await labeler.fileLabels;
expect(fileLabels.length).toBe(16)
expect(fileLabels[15]).toEqual(expect.objectContaining({ name: ":unicorn: Special" }))
expect(fileLabels[0]).toEqual(expect.objectContaining({ name: ":robot: bot", description: "I am robot" }))
expect(fileLabels[1]).toEqual(expect.objectContaining({ name: ":bug: bug", description: "Damn bugs" }))
expect(fileLabels.length).toBe(16);
expect(fileLabels[15]).toEqual(expect.objectContaining({name: ':unicorn: Special'}));
expect(fileLabels[0]).toEqual(expect.objectContaining({name: ':robot: bot', description: 'I am robot'}));
expect(fileLabels[1]).toEqual(expect.objectContaining({name: ':bug: bug', description: 'Damn bugs'}));
expect(() => labeler.run()).not.toThrow();
})
});
});

0 comments on commit c262250

Please sign in to comment.