jmettraux / ruote-rest

restful workflow engine based on Rack and ruote (Warning : ruote-rest will be replaced by ruote-kit soon)

ruote-rest / test / st_service.rb
100644 34 lines (21 sloc) 0.439 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#
# Testing ruote-rest
#
# John Mettraux at OpenWFE dot org
#
# Sun Apr 13 14:44:10 JST 2008
#
 
require File.dirname(__FILE__) + '/testbase'
 
 
class StServiceTest < Test::Unit::TestCase
 
  include TestBase
 
 
  def test_0
 
    get "/service.json"
 
    #p @response
    #puts @response.body
 
    assert_equal(
      "application/json",
      @response.content_type)
 
    a = json_parse(@response.body)
 
    assert_equal 6, a.size
  end
end