 
 polvo = require '../../lib/polvo'
 
-
-base = path.join __dirname, '..', 'mocks', 'basic'
-files = 
-  pack: path.join base, 'package.json'
-  app: path.join base, 'src', 'app', 'app.coffee'
-  config: path.join base, 'polvo.yml'
-  js: path.join base, 'public', 'app.js'
-  css: path.join base, 'public', 'app.css'
-
-config = """
+# basic mock
+basic = path.join __dirname, '..', 'mocks', 'basic'
+basic_files = 
+  basic_pack: path.join basic, 'package.json'
+  app: path.join basic, 'src', 'app', 'app.coffee'
+  basic_config: path.join basic, 'polvo.yml'
+  js: path.join basic, 'public', 'app.js'
+  css: path.join basic, 'public', 'app.css'
+
+basic_config = """
 server:
   port: 8080
   root: ./public

boot: src/app/app
"""

pack = '{"name": "basic"}'


describe '[polvo]', ->

  before ->
    fs.unlinkSync files.config if fs.existsSync files.config
    fs.unlinkSync files.pack if fs.existsSync files.pack
    fs.unlinkSync files.js if fs.existsSync files.js
    fs.unlinkSync files.css if fs.existsSync files.css

    fs.writeFileSync files.config, config

  afterEach ->
    mods = [

        outs++
        checker.test(msg).should.be.true

    fs.writeFileSync basic_files.basic_pack, basic_pack
    compile = polvo options, stdio

    outs.should.equal 2
