         { process: { on: (callback) -> } }
 
       staged = null
-      GitBridge.isStaged checkPath, (err, b) ->
+      GitBridge.isStaged repo, checkPath, (err, b) ->
         throw err if err
         staged = b
       staged

      { process: { on: (callback) -> } }

    called = false
    GitBridge.checkoutSide 'ours', 'lib/file1.txt', (err) ->
      throw err if err
      called = true

    expect(called).toBe(true)
    expect(c).toBe('/usr/bin/git')
    expect(a).toEqual(['checkout', '--ours', 'lib/file1.txt'])
    expect(o).toEqual({ cwd: repoBase() })

  it 'stages changes to a file', ->
    [c, a, o] = []

      exit(0)

    called = false
    GitBridge.add repo, 'lib/file1.txt', (err) ->
      throw err if err
      called = true

    expect(called).toBe(true)
    expect(c).toBe('/usr/bin/git')
    expect(a).toEqual(['add', 'lib/file1.txt'])
    expect(o).toEqual({ cwd: gitWorkDir })

  describe 'rebase detection', ->

