epp-eis 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,7 +3,7 @@ module Epp
3
3
 
4
4
  XML_NS_CONTACT = 'http://www.nic.cz/xml/epp/contact-1.6'
5
5
 
6
- XML_SCHEMALOC = 'http://www.nic.cz/xml/epp/contact-1.6 contact-1.6.xsd'
6
+ XML_CONTACT_SCHEMALOC = 'http://www.nic.cz/xml/epp/contact-1.6 contact-1.6.xsd'
7
7
 
8
8
  class ContactCheck
9
9
  attr_accessor :name, :available, :reason
@@ -151,7 +151,7 @@ module Epp
151
151
  builder = build_epp_request do |xml|
152
152
  xml.command {
153
153
  xml.check {
154
- xml.check('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_SCHEMALOC) {
154
+ xml.check('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_CONTACT_SCHEMALOC) {
155
155
  xml.parent.namespace = xml.parent.namespace_definitions.first
156
156
  contacts.each { |contact| xml.id_ contact }
157
157
  }
@@ -168,7 +168,7 @@ module Epp
168
168
  builder = build_epp_request do |xml|
169
169
  xml.command {
170
170
  xml.create {
171
- xml.create('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_SCHEMALOC) {
171
+ xml.create('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_CONTACT_SCHEMALOC) {
172
172
  xml.parent.namespace = xml.parent.namespace_definitions.first
173
173
  xml.id_ contact
174
174
  xml.postalInfo {
@@ -198,7 +198,7 @@ module Epp
198
198
  builder = build_epp_request do |xml|
199
199
  xml.command {
200
200
  xml.delete {
201
- xml.delete('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_SCHEMALOC) {
201
+ xml.delete('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_CONTACT_SCHEMALOC) {
202
202
  xml.parent.namespace = xml.parent.namespace_definitions.first
203
203
  xml.id_ contact
204
204
  }
@@ -215,7 +215,7 @@ module Epp
215
215
  builder = build_epp_request do |xml|
216
216
  xml.command {
217
217
  xml.info {
218
- xml.info('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_SCHEMALOC) {
218
+ xml.info('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_CONTACT_SCHEMALOC) {
219
219
  xml.parent.namespace = xml.parent.namespace_definitions.first
220
220
  xml.id_ contact
221
221
  }
@@ -236,7 +236,7 @@ module Epp
236
236
  builder = build_epp_request do |xml|
237
237
  xml.command {
238
238
  xml.update {
239
- xml.update('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_SCHEMALOC) {
239
+ xml.update('xmlns:contact' => XML_NS_CONTACT, 'xsi:schemaLocation' => XML_CONTACT_SCHEMALOC) {
240
240
  xml.parent.namespace = xml.parent.namespace_definitions.first
241
241
  xml.id_ contact
242
242
  if [name, street, city, postal_code, country_code].any?{ |item| !item.nil? }
@@ -1,8 +1,6 @@
1
1
  module Epp
2
2
  module Eis
3
3
 
4
- XML_NS_FRED = 'http://www.nic.cz/xml/epp/fred-1.4'
5
-
6
4
  class CreditInfoResponse
7
5
  def initialize(response)
8
6
  @response = Nokogiri::XML(response)
@@ -3,7 +3,7 @@ module Epp
3
3
 
4
4
  XML_NS_DOMAIN = 'http://www.nic.cz/xml/epp/domain-1.4'
5
5
 
6
- XML_SCHEMALOC = 'http://www.nic.cz/xml/epp/domain-1.4.xsd domain-1.4.xsd'
6
+ XML_DOMAIN_SCHEMALOC = 'http://www.nic.cz/xml/epp/domain-1.4.xsd domain-1.4.xsd'
7
7
 
8
8
  class DomainCreateResponse
9
9
  def initialize(response)
@@ -211,7 +211,7 @@ module Epp
211
211
  builder = build_epp_request do |xml|
212
212
  xml.command {
213
213
  xml.create {
214
- xml.create('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
214
+ xml.create('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
215
215
  xml.parent.namespace = xml.parent.namespace_definitions.first
216
216
  xml.name domain
217
217
  xml.period '1', 'unit' => 'y'
@@ -239,7 +239,7 @@ module Epp
239
239
  builder = build_epp_request do |xml|
240
240
  xml.command {
241
241
  xml.delete {
242
- xml.delete('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
242
+ xml.delete('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
243
243
  xml.parent.namespace = xml.parent.namespace_definitions.first
244
244
  xml.name domain
245
245
  }
@@ -263,7 +263,7 @@ module Epp
263
263
  builder = build_epp_request do |xml|
264
264
  xml.command {
265
265
  xml.info {
266
- xml.info('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
266
+ xml.info('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
267
267
  xml.parent.namespace = xml.parent.namespace_definitions.first
268
268
  xml.name domain
269
269
  }
@@ -285,7 +285,7 @@ module Epp
285
285
  builder = build_epp_request do |xml|
286
286
  xml.command {
287
287
  xml.renew {
288
- xml.renew('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
288
+ xml.renew('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
289
289
  xml.parent.namespace = xml.parent.namespace_definitions.first
290
290
  xml.name domain
291
291
  xml.curExpDate current_expire_date
@@ -309,7 +309,7 @@ module Epp
309
309
  builder = build_epp_request do |xml|
310
310
  xml.command {
311
311
  xml.transfer('op' => 'request') {
312
- xml.transfer('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
312
+ xml.transfer('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
313
313
  xml.parent.namespace = xml.parent.namespace_definitions.first
314
314
  xml.name domain
315
315
  xml.authInfo auth_info
@@ -339,7 +339,7 @@ module Epp
339
339
  builder = build_epp_request do |xml|
340
340
  xml.command {
341
341
  xml.update {
342
- xml.update('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
342
+ xml.update('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
343
343
  xml.parent.namespace = xml.parent.namespace_definitions.first
344
344
  xml.name domain
345
345
  if !add_admins.nil? && !add_admins.empty?
@@ -380,7 +380,7 @@ module Epp
380
380
  builder = build_epp_request do |xml|
381
381
  xml.command {
382
382
  xml.check {
383
- xml.check('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_SCHEMALOC) {
383
+ xml.check('xmlns:domain' => XML_NS_DOMAIN, 'xsi:schemaLocation' => XML_DOMAIN_SCHEMALOC) {
384
384
  xml.parent.namespace = xml.parent.namespace_definitions.first
385
385
  domains.each do |domain|
386
386
  xml.name domain
data/lib/epp-eis/nsset.rb CHANGED
@@ -3,7 +3,7 @@ module Epp
3
3
 
4
4
  XML_NS_NSSET = 'http://www.nic.cz/xml/epp/nsset-1.2'
5
5
 
6
- XML_SCHEMALOC = 'http://www.nic.cz/xml/epp/nsset-1.2 nsset-1.2.xsd'
6
+ XML_NSSET_SCHEMALOC = 'http://www.nic.cz/xml/epp/nsset-1.2 nsset-1.2.xsd'
7
7
 
8
8
  class NssetCheck
9
9
  attr_accessor :name, :available
@@ -131,7 +131,7 @@ module Epp
131
131
  builder = build_epp_request do |xml|
132
132
  xml.command {
133
133
  xml.check {
134
- xml.check('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_SCHEMALOC) {
134
+ xml.check('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_NSSET_SCHEMALOC) {
135
135
  xml.parent.namespace = xml.parent.namespace_definitions.first
136
136
  nssets.each { |nsset| xml.id_ nsset }
137
137
  }
@@ -148,7 +148,7 @@ module Epp
148
148
  builder = build_epp_request do |xml|
149
149
  xml.command {
150
150
  xml.create {
151
- xml.create('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_SCHEMALOC) {
151
+ xml.create('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_NSSET_SCHEMALOC) {
152
152
  xml.parent.namespace = xml.parent.namespace_definitions.first
153
153
  xml.id_ nsset
154
154
  nameservers.each do |nameserver|
@@ -172,7 +172,7 @@ module Epp
172
172
  builder = build_epp_request do |xml|
173
173
  xml.command {
174
174
  xml.delete {
175
- xml.delete('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_SCHEMALOC) {
175
+ xml.delete('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_NSSET_SCHEMALOC) {
176
176
  xml.parent.namespace = xml.parent.namespace_definitions.first
177
177
  xml.id_ nsset
178
178
  }
@@ -189,7 +189,7 @@ module Epp
189
189
  builder = build_epp_request do |xml|
190
190
  xml.command {
191
191
  xml.info {
192
- xml.info('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_SCHEMALOC) {
192
+ xml.info('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_NSSET_SCHEMALOC) {
193
193
  xml.parent.namespace = xml.parent.namespace_definitions.first
194
194
  xml.id_ nsset
195
195
  }
@@ -211,7 +211,7 @@ module Epp
211
211
  builder = build_epp_request do |xml|
212
212
  xml.command {
213
213
  xml.update {
214
- xml.update('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_SCHEMALOC) {
214
+ xml.update('xmlns:nsset' => XML_NS_NSSET, 'xsi:schemaLocation' => XML_NSSET_SCHEMALOC) {
215
215
  xml.parent.namespace = xml.parent.namespace_definitions.first
216
216
  xml.id_ nsset
217
217
  if add_nameservers or add_contact
@@ -1,8 +1,6 @@
1
1
  module Epp
2
2
  module Eis
3
3
 
4
- XML_NS_FRED = 'http://www.nic.cz/xml/epp/fred-1.4'
5
-
6
4
  class GetResultsResponse
7
5
  def initialize(response)
8
6
  @response = Nokogiri::XML(response)
@@ -1,5 +1,5 @@
1
1
  module Eis
2
2
  module Epp
3
- VERSION = '1.0.0'
3
+ VERSION = '1.0.1'
4
4
  end
5
5
  end
data/lib/epp-eis.rb CHANGED
@@ -7,3 +7,10 @@ require 'epp-eis/extensions'
7
7
  require 'epp-eis/domain'
8
8
  require 'epp-eis/contact'
9
9
  require 'epp-eis/nsset'
10
+
11
+ module Epp
12
+ module Eis
13
+
14
+ XML_NS_FRED = 'http://www.nic.cz/xml/epp/fred-1.4'
15
+ end
16
+ end
@@ -7,7 +7,7 @@ describe 'hello' do
7
7
 
8
8
  context 'when response is successful' do
9
9
  before(:each) do
10
- @server.stub(:request).and_return(xml_mock('responses/session/hello.xml'))
10
+ @server.stub(:send_request).and_return(xml_mock('responses/session/hello.xml'))
11
11
  @response = @server.hello
12
12
  end
13
13
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: epp-eis
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 0
10
- version: 1.0.0
9
+ - 1
10
+ version: 1.0.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Priit Haamer