spec/lib/endpoint.rb in rbovirt-0.0.15 vs spec/lib/endpoint.rb in rbovirt-0.0.16

- old
+ new

@@ -1,14 +1,18 @@ module OVIRT::RSpec::Endpoint - def endpoint - file = File.expand_path("../endpoint.yml", File.dirname(__FILE__)) - @endpoint ||= YAML.load(File.read(file)) + def endpoint + file = File.expand_path("../endpoint.yml", File.dirname(__FILE__)) + @endpoint ||= YAML.load(File.read(file)) user = @endpoint['user'] password= @endpoint['password'] hostname = @endpoint['hostname'] port = @endpoint['port'] url = "http://#{hostname}:#{port}/api" return user, password, url + end + + def support_user_level_api + @endpoint['version'] && @endpoint['version'] > 3.1 end end \ No newline at end of file