 
 module.exports = ->
 
-  this.Before (callback)->
+  @Before (callback)->
     TestSystem ?= require '../support/test_system'
     system = TestSystem
     callback()
 
-  this.Given /^the System is$/, (source, callback) ->
+  @Given /^the System is$/, (source, callback) ->
     try
       system = TestSystem.parse(source)
     catch e


    callback()

  this.Given /^I dress the following JSON document with (.*?):$/, (type, doc, callback) ->
    try
      json = JSON.parse(doc)
      result = system.fetch(type).dress(json)


    callback()

  @Given /^I dress JSON's '(.*?)' with (.*?)$/, (jsonValue, typename, callback) ->
    try
      json = JSON.parse(jsonValue)
      result = system.fetch(typename).dress(json)
    catch e
      result = e

    callback()

  @Given /^I dress the following JSON document:$/, (doc, callback) ->
    try
      json = JSON.parse(doc)
      result = system.dress(json)
