waw 0.2.2 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. data/bin/waw-crawl +26 -0
  2. data/lib/waw.rb +3 -3
  3. data/lib/waw/commands/command.rb +12 -4
  4. data/lib/waw/commands/crawl_command.rb +46 -0
  5. data/lib/waw/commands/profile_command.rb +5 -1
  6. data/lib/waw/controllers/action/action.rb +11 -0
  7. data/lib/waw/controllers/action/js_generation.rb +11 -2
  8. data/lib/waw/controllers/static/match.rb +4 -1
  9. data/lib/waw/controllers/static/matcher.rb +35 -0
  10. data/lib/waw/controllers/static/waw_access.rb +28 -15
  11. data/lib/waw/controllers/static/waw_access_dsl.rb +9 -0
  12. data/lib/waw/controllers/static_controller.rb +5 -2
  13. data/lib/waw/crawler.rb +176 -0
  14. data/lib/waw/crawler/crawler_listener.rb +64 -0
  15. data/lib/waw/crawler/crawler_options.rb +42 -0
  16. data/lib/waw/kern/living_state.rb +93 -0
  17. data/lib/waw/scope_utils.rb +1 -0
  18. data/lib/waw/tools/mail/mail_agent.rb +1 -1
  19. data/lib/waw/validation.rb +3 -0
  20. data/lib/waw/validation/datetime_validator.rb +53 -0
  21. data/lib/waw/wspec/browser.rb +4 -2
  22. data/test/bricks/error_handler/test/test_all.rb +20 -0
  23. data/test/bricks/static_controller/config/test.cfg +2 -0
  24. data/test/bricks/static_controller/logs/webapp.log +84 -0
  25. data/test/bricks/static_controller/test/static_controller.wspec +12 -0
  26. data/test/bricks/static_controller/test/test_all.rb +20 -0
  27. data/test/bricks/static_controller/waw.deploy +1 -0
  28. data/test/bricks/static_controller/waw.routing +5 -0
  29. data/test/bricks/test_all.rb +8 -0
  30. data/test/spec/controllers/static/waw_access_spec.rb +3 -3
  31. data/test/spec/test_all.rb +0 -2
  32. data/test/spec/validation/datetime_validation_spec.rb +92 -0
  33. data/test/unit/test_all.rb +1 -0
  34. data/test/unit/waw/controllers/static/logs/webapp.log +22 -0
  35. metadata +23 -6
@@ -0,0 +1,64 @@
1
+ require 'highline'
2
+ module Waw
3
+ class Crawler
4
+ class Listener
5
+
6
+ attr_reader :highline
7
+ attr_accessor :verbosity
8
+
9
+ # Creates a listener instance
10
+ def initialize(output)
11
+ @highline = HighLine.new(STDIN, output)
12
+ @verbosity = 1
13
+ end
14
+
15
+ def checking(page, &block)
16
+ if verbosity > 0
17
+ highline.say page.uri.to_s
18
+ end
19
+ block.call
20
+ end
21
+
22
+ def doc_skipped(to_check)
23
+ if verbosity > 1
24
+ highline.say highline.color(to_check.uri, :magenta)
25
+ end
26
+ end
27
+
28
+ def crawl_skipped(referer_page, location)
29
+ if verbosity > 1
30
+ highline.say ' + crawling skipped: ' + highline.color(location, :magenta)
31
+ end
32
+ end
33
+
34
+ def ping_ok(referer_page, location)
35
+ if verbosity > 1
36
+ highline.say ' + ping ok: ' + highline.color(location, :green)
37
+ end
38
+ end
39
+
40
+ def ping_skipped(referer_page, location)
41
+ if verbosity > 1
42
+ highline.say ' + ping skipped: ' + highline.color(location, :magenta)
43
+ end
44
+ end
45
+
46
+ def reach_failure(referer_page, location, ex)
47
+ highline.say ' + reach failure: ' + highline.color(location, :red)
48
+ end
49
+
50
+ def scheme_failure(referer_page, location, ex)
51
+ if verbosity > 1
52
+ highline.say ' + scheme failure: ' + highline.color(location, :magenta)
53
+ end
54
+ end
55
+
56
+ def socket_error(referer_page, location, ex)
57
+ if verbosity > 1
58
+ highline.say ' + socket failure: ' + highline.color(location, :magenta)
59
+ end
60
+ end
61
+
62
+ end # class Listener
63
+ end # module Crawler
64
+ end # module Waw
@@ -0,0 +1,42 @@
1
+ module Waw
2
+ class Crawler
3
+ module Options
4
+
5
+ # XPath queries for ping
6
+ attr_accessor :ping_list
7
+
8
+ # XPath queries for crawl
9
+ attr_accessor :crawl_list
10
+
11
+ # Checks links that lead outside the website?
12
+ attr_accessor :check_externals
13
+
14
+ # Listener to use
15
+ attr_accessor :listener
16
+
17
+ def set_default_options
18
+ @ping_list = [
19
+ 'link/@href',
20
+ 'img/@src',
21
+ 'script/@src',
22
+ 'a/@href'
23
+ ]
24
+ @crawl_list = [
25
+ 'a/@href'
26
+ ]
27
+ @check_externals = false
28
+ @listener = Crawler::Listener.new(STDOUT)
29
+ end
30
+
31
+ # Set/unset an XPath query to ping
32
+ def ping_on(query, value = true)
33
+ if value
34
+ ping_list << query
35
+ else
36
+ ping_list.delete(query)
37
+ end
38
+ end
39
+
40
+ end # module Options
41
+ end # module Crawler
42
+ end # module Waw
@@ -36,6 +36,99 @@ module Waw
36
36
 
37
37
  end # class Saved
38
38
 
39
+ # Handler called to install everything required for the living
40
+ # state to work properly, based on a Rack env variable.
41
+ def install_living_state(env)
42
+ stack = (Thread.current[:waw_state] ||= [])
43
+ state = Saved.new(env)
44
+ stack.push(state)
45
+ state
46
+ end
47
+
48
+ # Cleans the living state when a request is done.
49
+ def clean_living_state
50
+ if (stack = Thread.current[:waw_state])
51
+ stack.pop
52
+ end
53
+ end
54
+
55
+ # Returns the current waw_state object
56
+ def waw_state
57
+ install_living_state({}) if Thread.current[:waw_state].nil?
58
+ Thread.current[:waw_state].first
59
+ end
60
+
61
+ # Returns the current Rack env instance
62
+ def rack_env
63
+ waw_state.rack_env
64
+ end
65
+
66
+ # Returns the current Rack request instance
67
+ def request
68
+ waw_state.rack_request
69
+ end
70
+
71
+ # Returns the current Rack request instance
72
+ def response
73
+ waw_state.rack_response
74
+ end
75
+
76
+ # Request parameters
77
+ def params
78
+ request && request.params
79
+ end
80
+
81
+ # Returns the current Rack session
82
+ def real_session
83
+ waw_state.rack_session
84
+ end
85
+
86
+ # Returns the waw session decorator
87
+ def session
88
+ waw_state.waw_session
89
+ end
90
+
91
+ end # module LivingState
92
+ end # module Kern
93
+ end # module Waw
94
+ module Waw
95
+ module Kern
96
+ # Variables that are living during a web request.
97
+ module LivingState
98
+
99
+ # The living state object itself
100
+ class Saved
101
+
102
+ # Rack environment
103
+ attr_reader :rack_env
104
+
105
+ # Creates a saved instance
106
+ def initialize(rack_env)
107
+ @rack_env = rack_env
108
+ end
109
+
110
+ # Current request
111
+ def rack_request
112
+ @rack_request ||= Rack::Request.new(rack_env)
113
+ end
114
+
115
+ # Current response
116
+ def rack_response
117
+ @rack_response ||= Rack::Response.new(rack_env)
118
+ end
119
+
120
+ # Rack session object
121
+ def rack_session
122
+ @rack_session ||= (rack_env['rack.session'] ||= {})
123
+ end
124
+
125
+ # Waw session
126
+ def waw_session
127
+ @session ||= ::Waw::Session.new(rack_session)
128
+ end
129
+
130
+ end # class Saved
131
+
39
132
  # Handler called to install everything required for the living
40
133
  # state to work properly, based on a Rack env variable.
41
134
  def install_living_state(env)
@@ -8,6 +8,7 @@ module Waw
8
8
  Waw.logger.warn("Using a empty kernel because no one has been found")
9
9
  Waw::Kern::App.new("Empty autoloaded kernel").autoload(File.join(File.dirname(__FILE__), 'kern', 'empty'))
10
10
  end
11
+ alias :kernel :find_kernel_context
11
12
 
12
13
  ################################################################# About waw application
13
14
 
@@ -109,7 +109,7 @@ module Waw
109
109
  smtp_conn.send_message(mail.dump, mail.from, *mail.to)
110
110
  smtp_conn.finish
111
111
  else
112
- Waw.logger.debug mail.dump
112
+ #Waw.logger.debug mail.dump
113
113
  sent = Mail.parse(mail.dump)
114
114
  mail.to.each {|who| mailbox(who) << sent.dup}
115
115
  mail.cc.each {|who| mailbox(who) << sent.dup}
@@ -17,6 +17,7 @@ require 'waw/validation/string_validator'
17
17
  require 'waw/validation/integer_validator'
18
18
  require 'waw/validation/float_validator'
19
19
  require 'waw/validation/date_validator'
20
+ require 'waw/validation/datetime_validator'
20
21
  require 'waw/validation/regexp_validator'
21
22
 
22
23
  require 'waw/validation/comparison_validations'
@@ -151,6 +152,8 @@ module Waw
151
152
  validator :integer, ::Waw::Validation::IntegerValidator.new
152
153
  validator :float, ::Waw::Validation::FloatValidator.new
153
154
  validator :date, ::Waw::Validation::DateValidator.new
155
+ validator :datetime, ::Waw::Validation::DateTimeValidator
156
+ validator :regexp, ::Waw::Validation::RegexpValidator
154
157
  ruby_class_to_validator(::Boolean, boolean)
155
158
  ruby_class_to_validator(::String, string)
156
159
  ruby_class_to_validator(::Integer, integer)
@@ -0,0 +1,53 @@
1
+ require 'date'
2
+ require 'time'
3
+ module Waw
4
+ module Validation
5
+ class DateTimeValidator < Validator
6
+
7
+ # Creates a validator instance with options
8
+ def initialize(options = {})
9
+ @options = options
10
+ end
11
+
12
+ def date_format
13
+ @options[:date_format] || '%Y/%m/%d'
14
+ end
15
+
16
+ # Returns a Date object if value seems a date, nil otherwise
17
+ def seems_a_date?(value)
18
+ Date.strptime(value.to_s, date_format)
19
+ rescue ArgumentError => ex
20
+ nil
21
+ end
22
+
23
+ # Returns a Date object if value seems a date, nil otherwise
24
+ def seems_a_time?(value, date)
25
+ if value.to_s.empty?
26
+ false
27
+ else
28
+ Time.parse(value.to_s, date)
29
+ end
30
+ rescue ArgumentError => ex
31
+ nil
32
+ end
33
+
34
+ def validate(*values)
35
+ convert_and_validate(*values)[0]
36
+ end
37
+
38
+ def convert_and_validate(*values)
39
+ date = seems_a_date?(values[0])
40
+ if date.nil?
41
+ [false, values]
42
+ else
43
+ if time = seems_a_time?(values[1], date)
44
+ [true, [date, time]]
45
+ else
46
+ [false, values]
47
+ end
48
+ end
49
+ end
50
+
51
+ end # class DateTimeValidator
52
+ end # module Validation
53
+ end # module Waw
@@ -43,6 +43,7 @@ module Waw
43
43
  def relative_uri(uri)
44
44
  raise ArgumentError, "relative_uri: uri may not be nil" if uri.nil?
45
45
  uri = ensure_uri(uri)
46
+ new_location = nil
46
47
  if uri.path[0...1] == '/'
47
48
  new_location = base.dup
48
49
  new_location.path = uri.path
@@ -50,17 +51,18 @@ module Waw
50
51
  new_location
51
52
  else
52
53
  new_location = base.dup
53
- new_location.path = '/' + uri.path
54
+ new_location.path = File.dirname(new_location.path) + '/' + uri.path
54
55
  new_location.query = uri.query
55
56
  new_location
56
57
  end
58
+ new_location
57
59
  end
58
60
 
59
61
  #################################################################### Query utilities
60
62
 
61
63
  # Looks for the base of the website
62
64
  def base
63
- @base ||= find_base
65
+ find_base
64
66
  end
65
67
 
66
68
  # Finds the base of the current location
@@ -0,0 +1,20 @@
1
+ # Requires
2
+ begin
3
+ top = File.expand_path(File.join(File.dirname(__FILE__), '..', '..', '..', '..', 'lib'))
4
+ $LOAD_PATH.unshift(top)
5
+ require 'waw'
6
+ rescue LoadError => ex
7
+ require 'rubygems'
8
+ gem 'waw', '>= 0.2.0'
9
+ require 'waw'
10
+ end
11
+ require 'waw/wspec/runner'
12
+
13
+ # Load the waw application for having configuration
14
+ app = Waw.autoload(__FILE__)
15
+ raise "Tests cannot be run in production mode, to avoid modifying real database "\
16
+ "or sending spam mails to real users." unless ['devel', 'test'].include?(app.config.deploy_mode)
17
+
18
+ # Load all tests now
19
+ test_files = Dir[File.join(File.dirname(__FILE__), '**/*.wspec')]
20
+ test_files.each { |file| load(file) }
@@ -0,0 +1,2 @@
1
+ deploy_mode 'devel'
2
+ web_base 'http://127.0.0.1:9292/'
@@ -0,0 +1,84 @@
1
+ # Logfile created on Fri Oct 29 14:16:29 +0200 2010 by logger.rb/22285
2
+ I, [2010-10-29T14:16:29.294180 #83380] INFO -- : Waw::Kern::App: load stage 1 sucessfull (test)
3
+ I, [2010-10-29T14:16:29.294270 #83380] INFO -- : Waw::Kern::App: load stage 2 sucessfull
4
+ W, [2010-10-29T14:16:29.294362 #83380] WARN -- : Ignoring the resources folder (not readable)... something will probably fail later!
5
+ I, [2010-10-29T14:16:29.294429 #83380] INFO -- : Waw::Kern::App: load stage 3 sucessfull (resources)
6
+ I, [2010-10-29T14:16:29.296181 #83380] INFO -- : Waw::Kern::App: load stage 4 sucessfull (using waw.routing)
7
+ I, [2010-10-29T14:16:29.296335 #83380] INFO -- : Waw::Kern::App: load stage 5 sucessfull (load hooks executed)
8
+ I, [2010-10-29T14:16:29.296402 #83380] INFO -- : Waw::Kern::App: application loaded successfully, enjoy!
9
+ E, [2010-10-29T14:16:29.430668 #83380] ERROR -- : Fatal error undefined local variable or method `reqpath' for #<Waw::StaticController::Matcher:0x1236440>
10
+ E, [2010-10-29T14:16:29.431149 #83380] ERROR -- : (eval):4:in `dsl_merge'
11
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/matcher.rb:30:in `instance_eval'
12
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/matcher.rb:30:in `matches?'
13
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:194:in `find_match'
14
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:172:in `each'
15
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:172:in `find_match'
16
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:206:in `apply_rules'
17
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:238:in `do_path_serve'
18
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:243:in `call'
19
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static_controller.rb:36:in `call'
20
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:47:in `call'
21
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:41:in `each'
22
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:41:in `call'
23
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/kern/app.rb:22:in `call'
24
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/content_length.rb:13:in `call'
25
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/chunked.rb:15:in `call'
26
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/handler/mongrel.rb:67:in `process'
27
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:159:in `process_client'
28
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:158:in `each'
29
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:158:in `process_client'
30
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `run'
31
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `initialize'
32
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `new'
33
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `run'
34
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `initialize'
35
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `new'
36
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `run'
37
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/handler/mongrel.rb:38:in `run'
38
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:28:in `waw_start'
39
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `initialize'
40
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `new'
41
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `waw_start'
42
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:52:in `__run'
43
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/command.rb:63:in `run'
44
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/waw-start:15
45
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/bin/waw-start:19:in `load'
46
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/bin/waw-start:19
47
+ E, [2010-10-29T14:16:31.668329 #83380] ERROR -- : Fatal error undefined local variable or method `reqpath' for #<Waw::StaticController::Matcher:0x1236440>
48
+ E, [2010-10-29T14:16:31.668545 #83380] ERROR -- : (eval):4:in `dsl_merge'
49
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/matcher.rb:30:in `instance_eval'
50
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/matcher.rb:30:in `matches?'
51
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:194:in `find_match'
52
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:172:in `each'
53
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:172:in `find_match'
54
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:206:in `apply_rules'
55
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:238:in `do_path_serve'
56
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static/waw_access.rb:243:in `call'
57
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/controllers/static_controller.rb:36:in `call'
58
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:47:in `call'
59
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:41:in `each'
60
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/urlmap.rb:41:in `call'
61
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/kern/app.rb:22:in `call'
62
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/content_length.rb:13:in `call'
63
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/chunked.rb:15:in `call'
64
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/handler/mongrel.rb:67:in `process'
65
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:159:in `process_client'
66
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:158:in `each'
67
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:158:in `process_client'
68
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `run'
69
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `initialize'
70
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `new'
71
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:285:in `run'
72
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `initialize'
73
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `new'
74
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/lib/mongrel.rb:268:in `run'
75
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/rack-1.2.1/lib/rack/handler/mongrel.rb:38:in `run'
76
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:28:in `waw_start'
77
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `initialize'
78
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `new'
79
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:21:in `waw_start'
80
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/start_command.rb:52:in `__run'
81
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/../lib/waw/commands/command.rb:63:in `run'
82
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/gems/waw-0.3.0/bin/waw-start:15
83
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/bin/waw-start:19:in `load'
84
+ /Users/blambeau/.rvm/gems/ruby-1.8.7-p299/bin/waw-start:19
@@ -0,0 +1,12 @@
1
+ requirement("Friendly static control should be provided by waw") {
2
+
3
+ browser.location = index_page + "not_existing"
4
+ i_see "Not found"
5
+
6
+ browser.location = index_page + "hello"
7
+ i_see "[a-z]+"
8
+
9
+ browser.location = index_page + "123"
10
+ i_see "is_number"
11
+
12
+ }