Sha256: c3ef110d3b297cbd78e15323d72c9c7eeec53d100092ff768527e5ffc8927975
Contents?: true
Size: 788 Bytes
Versions: 5
Compression:
Stored size: 788 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + "/test_helper") class ConnectionTestRobot < Artoo::Robot connection :test_connection end describe Artoo::Connection do before do @robot = ConnectionTestRobot.new @connection = @robot.default_connection end it 'Artoo::Connection#connect' do @connection.connect @connection.adaptor.class.must_equal Artoo::Adaptors::Loopback end it 'Artoo::Connection#disconnect' do @connection.connect @connection.disconnect @connection.connected?.must_equal false end it 'Artoo::Connection#as_json' do MultiJson.load(@connection.as_json, :symbolize_keys => true)[:name].must_equal "test_connection" MultiJson.load(@connection.as_json, :symbolize_keys => true)[:connected].must_equal false end end
Version data entries
5 entries across 5 versions & 1 rubygems