Class: Sappho::Socket::MockSocketWrite
- Inherits:
-
Object
- Object
- Sappho::Socket::MockSocketWrite
- Defined in:
- lib/sappho-socket/mock_socket.rb
Instance Method Summary collapse
- #action(str) ⇒ Object
-
#initialize(str) ⇒ MockSocketWrite
constructor
A new instance of MockSocketWrite.
Constructor Details
#initialize(str) ⇒ MockSocketWrite
Returns a new instance of MockSocketWrite.
103 104 105 |
# File 'lib/sappho-socket/mock_socket.rb', line 103 def initialize str @str = str end |
Instance Method Details
#action(str) ⇒ Object
107 108 109 |
# File 'lib/sappho-socket/mock_socket.rb', line 107 def action str raise MockSocketSessionError, 'Unexpected string on write' unless str == @str end |