 			input = {
 				in: '*awesome*'
 				out: '<p><em>awesome</em></p>'
-				outPath: outPath+'/outpath-render.html'
+				outPath: pathUtil.join(outPath,'outpath-render.html')
 			}
-			balUtil.spawn [cliPath, 'render', 'markdown', '-o', input.outPath], {stdin:input.in, cwd:rootPath}, (err,stdout,stderr,code,signal) ->
+			balUtil.spawn [nodePath, cliPath, 'render', 'markdown', '-o', input.outPath], {stdin:input.in, cwd:rootPath}, (err,stdout,stderr,code,signal) ->
 				return done(err)  if err
 				expect(stdout).to.equal('')
-				balUtil.readFile outPath+'/outpath-render.html', (err,data) ->
+				balUtil.readFile input.outPath, (err,data) ->
 					return done(err)  if err
 					result = data.toString()
 					expect(result).to.equal(input.out)

		]
		balUtil.each inputs, (input) ->
			test input.testname, (done) ->
				command = [cliPath, 'render']
				command.push(input.filename)  if input.filename
				balUtil.spawn command, {stdin:input.stdin,cwd:rootPath}, (err,stdout,stderr,code,signal) ->
					return done(err)  if err

expect = chai.expect
joe = require('joe')
_ = require('underscore')
pathUtil = require('path')

# -------------------------------------
# Configuration

# Vars
docpadPath = pathUtil.join(__dirname,'..','..')
rootPath = pathUtil.join(docpadPath,'test')
renderPath = pathUtil.join(rootPath,'render')
outPath = pathUtil.join(rootPath,'render-out')
expectPath = pathUtil.join(rootPath,'render-expected')
cliPath = pathUtil.join(docpadPath,'bin','docpad')
nodePath = null

# -------------------------------------
