Navigation Menu

Skip to content

Commit

Permalink
Fix indent
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Apr 14, 2015
1 parent c6c87df commit 27721ed
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions lib/drntest/directive.rb
Expand Up @@ -81,15 +81,15 @@ def initialize(parameters)
@timeout_seconds = nil

parameters.each do |parameter|
if parameter =~ /\A(\d+)(?:messages|msg)?\z/
@max_messages = $1.to_i
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)s(?:ec(?:onds?)?)?\z/
@timeout_seconds = $1.to_f
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)m(?:inutes?)?\z/
@timeout_seconds = $1.to_f * ONE_MINUTE_IN_SECONDS
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)h(?:ours?)?\z/
@timeout_seconds = $1.to_f * ONE_HOUR_IN_SECONDS
end
if parameter =~ /\A(\d+)(?:messages|msg)?\z/
@max_messages = $1.to_i
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)s(?:ec(?:onds?)?)?\z/
@timeout_seconds = $1.to_f
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)m(?:inutes?)?\z/
@timeout_seconds = $1.to_f * ONE_MINUTE_IN_SECONDS
elsif parameter =~ /\A(\d+\.?|\.\d+|\d+\.\d+)h(?:ours?)?\z/
@timeout_seconds = $1.to_f * ONE_HOUR_IN_SECONDS
end
end

if @max_messages.nil? and @timeout_seconds.nil?
Expand Down

0 comments on commit 27721ed

Please sign in to comment.