Class: WhileUser
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- WhileUser
- Defined in:
- lib/spec/virtualizees/while_user.rb
Instance Method Summary collapse
-
#initialize(value) ⇒ WhileUser
constructor
A new instance of WhileUser.
- #while_count_to_value ⇒ Object
Constructor Details
#initialize(value) ⇒ WhileUser
Returns a new instance of WhileUser.
2 3 4 5 6 |
# File 'lib/spec/virtualizees/while_user.rb', line 2 def initialize(value) @value = value @i = 0 @counts = [] end |
Instance Method Details
#while_count_to_value ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'lib/spec/virtualizees/while_user.rb', line 8 def while_count_to_value while @i < @value @counts << @i @i += 1 end @counts end |