Skip to content

Commit

Permalink
Merge pull request #117 from cosmos/fabo/108-fix-gaia-api
Browse files Browse the repository at this point in the history
changed gaia commands to new api
  • Loading branch information
nylira authored Nov 28, 2017
2 parents 8c46976 + 43959e2 commit 07df35a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 15 deletions.
5 changes: 2 additions & 3 deletions app/src/main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ app.on('ready', () => createWindow())
async function startBaseserver (home) {
log('startBaseserver', home)
let child = startProcess(SERVER_BINARY, [
'server',
'serve',
'rest-server',
'--home', home // ,
// '--trust-node'
])
Expand Down Expand Up @@ -234,7 +233,7 @@ async function initBaseserver (chainId, home, node) {
// fs.ensureDirSync(home)
// `baseserver init` to generate config, trust seed
let child = startProcess(SERVER_BINARY, [
'server',
'client',
'init',
'--home', home,
'--chain-id', chainId,
Expand Down
20 changes: 8 additions & 12 deletions test/unit/specs/main.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('client') &&
args.includes('init') &&
args.splice(1).join('=').includes('--chain-id=gaia-1')
args.join('=').includes('--chain-id=gaia-1')
)
).toBeDefined()
})
Expand All @@ -78,8 +78,7 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('serve')
args.includes('rest-server')
)
).toBeDefined()
expect(main.processes.baseserverProcess).toBeDefined()
Expand Down Expand Up @@ -181,9 +180,9 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('client') &&
args.includes('init') &&
args.splice(1).join('=').includes('--chain-id=gaia-1')
args.join('=').includes('--chain-id=gaia-1')
)
).toBeDefined()
})
Expand All @@ -192,8 +191,7 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('serve')
args.includes('rest-server')
)
).toBeDefined()
expect(main.processes.baseserverProcess).toBeDefined()
Expand Down Expand Up @@ -239,8 +237,7 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('serve')
args.includes('rest-server')
)
).toBeDefined()
expect(main.processes.baseserverProcess).toBeDefined()
Expand Down Expand Up @@ -286,8 +283,7 @@ describe('Startup Process', () => {
expect(childProcess.spawn.mock.calls
.find(([path, args]) =>
path.includes('gaia') &&
args.includes('server') &&
args.includes('serve')
args.includes('rest-server')
).length
).toBeGreaterThan(1)
})
Expand Down

0 comments on commit 07df35a

Please sign in to comment.