Skip to content

Commit

Permalink
fix: set the atom electron version based on npmrc
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Jun 26, 2022
1 parent cfe93a1 commit e6f59ec
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions spec/install-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ const http = require("http")
const wrench = require("wrench")
import * as apm from "../lib/apm-cli"
import Install from "../lib/install"
import { sync as resolveSync } from "resolve"

const atomElectronVersion = fs.readFileSync(`${path.dirname(__dirname)}/.npmrc`, "utf8").match(/target=(.*)\n/)[1]

describe("apm install", function () {
let [atomHome, resourcePath] = Array.from([])
Expand Down Expand Up @@ -103,7 +104,7 @@ describe("apm install", function () {
process.env.ATOM_HOME = atomHome
process.env.ATOM_ELECTRON_URL = "http://localhost:3000/node"
process.env.ATOM_PACKAGES_URL = "http://localhost:3000/packages"
process.env.ATOM_ELECTRON_VERSION = "v10.20.1"
process.env.ATOM_ELECTRON_VERSION = atomElectronVersion
process.env.npm_config_registry = "http://localhost:3000/"
return (live = true)
})
Expand Down

0 comments on commit e6f59ec

Please sign in to comment.