 
 
   it 'executeCommand - should execute the hello-world command', ->
-    process.argv = ['node', 'main.js', 'hello-world']
+    process.argv = ['node', 'main.js', 'program-json', 'hello-world']
     cli.executeCommand()
     chai.assert logSpy.calledWith "Hello world from spacejamio:cli"
 
 
   it 'executeCommand - should execute the echo command with the default string', ->
-    process.argv = ['node', 'main.js', 'echo']
+    process.argv = ['node', 'main.js', 'program-json', 'echo']
     cli.executeCommand()
     chai.assert logSpy.calledWith "I am echoing the --string default"
 
 
   it 'executeCommand - should execute the echo command with a provided string', ->
-    process.argv = ['node', 'main.js', 'echo', '--string', 'I am echoing this string']
+    process.argv = ['node', 'main.js', 'program-json', 'echo', '--string', 'I am echoing this string']
     cli.executeCommand()
     chai.assert logSpy.calledWith "I am echoing this string"
 

    chai.assert logSpy.calledWith "Hello world from spacejamio:cli"
    expect(process.argv[0]).to.equal 'node'
    expect(process.argv[1]).to.equal 'main.js'
    expect(process.argv[2]).to.equal 'hello-world'


  it 'executeCommand - should fail if no command was provided', ->
    process.argv = ['node', 'main.js']
    expect(CLI.executeCommand).to.throw(Error)


  it 'executeCommand - should fail if command is not registered', ->
    process.argv = ['node', 'main.js', 'not-registered']
    expect(CLI.executeCommand).to.throw(Error)

    # We're cloning because rc mutates it's objects


  it 'registerCommand - should have hello-world and echo registered', ->
    expect(cli.registeredCommands['hello-world']).to.be.an 'object'
    expect(cli.registeredCommands['hello-world']).to.be.to.have.keys ['func', 'defaultOptions']
