 
 colors = require 'colors'
 _ = require 'underscore'
+{argv} = require 'optimist'
+
+
+interface =
+	bdd :
+		it : 'it'
+		describe : 'describe'
+	tdd :
+		it : 'test'
+		describe : 'suite'
+
+argv.ui = argv.ui ? argv.u  # mocha option --ui overwrites -u
+if argv.ui && (argv.ui == 'tdd' or _.last(argv.ui) == 'tdd')
+	ui = interface.tdd
+else
+	ui = interface.bdd  # Default
+
 
 exports.Feature = (feature, story..., callback)->
 	#  exp. Feature 'new feature', 'in order to do good', 'as a user', 'I want to do good', ->

	message = "Feature: #{feature} \n\n".green.underline
	(message += '\t'+part+'\n' for part in story)

	describe(message, callback)
	return

dic = (type, label, args, options={})->  # Dictate to describe() or it()


				

		fn = ->
			global[ui[type]] label, cb

		if options.padding
			global[ui.describe] '|'.green, ->
				fn()
		else
			fn()
