Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
Signed-off-by: Matteo Collina <hello@matteocollina.com>
  • Loading branch information
mcollina committed Jan 30, 2024
1 parent 4bb4699 commit 19c5edc
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions test/reporters.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ import { MarkdownReporter, GithubWorkflowFailuresReporter } from '../lib/reporte
import { test, describe } from 'node:test'
import { strictEqual } from 'node:assert'

const cwd = process.platform === 'win32' ? 'C:\\foo' : '/foo'

describe('MarkdownReporter', async () => {
test('should write a report', async () => {
const reporter = new MarkdownReporter({ cwd: '/foo' })
const reporter = new MarkdownReporter({ cwd })

// This is skipped
reporter.write({
Expand Down Expand Up @@ -65,7 +67,7 @@ describe('MarkdownReporter', async () => {
})

test('skip fail heading if no failing tests', async () => {
const reporter = new MarkdownReporter({ cwd: '/foo' })
const reporter = new MarkdownReporter({ cwd })

reporter.write({
type: 'test:pass',
Expand Down Expand Up @@ -109,7 +111,7 @@ describe('MarkdownReporter', async () => {

describe('GithubWorkflowFailuresReporter', async () => {
test('should write error in github format', async () => {
const reporter = new GithubWorkflowFailuresReporter({ cwd: '/foo' })
const reporter = new GithubWorkflowFailuresReporter({ cwd })

// This is skipped
reporter.write({
Expand Down

0 comments on commit 19c5edc

Please sign in to comment.