Sha256: c77e39e52a4566ab486aa2ad72612a4c83d98767ff9a99091890cbbefb53e8b4

Contents?: true

Size: 991 Bytes

Versions: 2

Compression:

Stored size: 991 Bytes

Contents

# encoding: utf-8

# bootstrap the environment
ENV['RACK_ENV'] = 'test'
lib_path = File.expand_path('../lib', __FILE__)
($:.unshift lib_path) unless ($:.include? lib_path)

# require dependencies
require 'bundler'
Bundler.setup(:default, ENV['RACK_ENV'])

# our humble test subject
require 'hyperdrive'

# Fire up the BDD Stack
require 'minitest/autorun'
require "minitest-spec-context"
require 'minitest/reporters'

#  all systems go
MiniTest::Reporters.use! MiniTest::Reporters::SpecReporter.new
#include Rack::Test::Methods

def sample_api
  hyperdrive do
    resource(:thing) do
      name 'Thing Resource'
      desc 'Description of Thing Resource'

      param :name, '50 Chars or less' 
      param :start_date, 'Format: YYYY-MM-DD', required: false
      param :end_date, 'Format: YYYY-MM-DD', required: false

      filter :start_date, 'Format: YYYY-MM-DD'
      filter :end_date, 'Format: YYYY-MM-DD'
      filter :parent_id, 'Parent ID of Thing', required: true
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
hyperdrive-0.0.5 spec/spec_helper.rb
hyperdrive-0.0.4 spec/spec_helper.rb