Skip to content

Commit

Permalink
fix: windows build
Browse files Browse the repository at this point in the history
  • Loading branch information
vasco-santos committed Jul 29, 2021
1 parent b62a869 commit ff580fe
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 16 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,14 @@
"esbuild-register": "^2.3.0",
"eslint": "^7.23.0",
"eslint-config-ipfs": "^2.0.0",
"execa": "https://gitpkg.now.sh/vasco-santos/execa?chore/debug",
"execa": "^5.1.1",
"extract-zip": "^2.0.1",
"fs-extra": "^10.0.0",
"gh-pages": "^3.1.0",
"git-authors-cli": "^1.0.33",
"globby": "^11.0.3",
"ipfs-utils": "^8.1.0",
"ipjs": "https://gitpkg.now.sh/vasco-santos/ipjs?chore/debug2",
"ipjs": "https://gitpkg.now.sh/vasco-santos/ipjs?fix/windows-build",
"it-glob": "~0.0.10",
"kleur": "^4.1.4",
"lilconfig": "^2.0.2",
Expand Down
17 changes: 3 additions & 14 deletions test/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,12 @@

const { expect } = require('../utils/chai')
const execa = require('execa')
const process = require('process')
const { copy, existsSync } = require('fs-extra')
const { join } = require('path')
const bin = require.resolve('../')
const tempy = require('tempy')

describe('build', () => {
// if (process.platform !== 'win32') {
describe('esm', () => {
let projectDir = ''

Expand All @@ -23,17 +21,9 @@ describe('build', () => {
it('should build an esm project', async function () {
this.timeout(20 * 1000) // slow ci is slow

try {
const run = execa(bin, ['build'], {
cwd: projectDir
})
// @ts-ignore
run.stdout.pipe(process.stdout)
await run
} catch (err) {
// eslint-disable-next-line
console.log('err', err)
}
await execa(bin, ['build'], {
cwd: projectDir
})

expect(existsSync(join(projectDir, 'dist', 'esm'))).to.be.true()
expect(existsSync(join(projectDir, 'dist', 'cjs'))).to.be.true()
Expand All @@ -44,5 +34,4 @@ describe('build', () => {
expect(module).to.have.property('useDerp').that.is.a('function')
})
})
// }
})

0 comments on commit ff580fe

Please sign in to comment.