forked from weppos/whois
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request weppos#181 from JustinCampbell/register-enom
Fix whois.register.com parser for enom formats
- Loading branch information
Showing
4 changed files
with
364 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
91 changes: 91 additions & 0 deletions
91
spec/fixtures/responses/whois.register.com/status_registered_2.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
#status | ||
should: %s raise_error(Whois::PropertyNotSupported) | ||
|
||
#available? | ||
should: %s == false | ||
|
||
#registered? | ||
should: %s == true | ||
|
||
|
||
#created_on | ||
should: %s CLASS(time) | ||
should: %s == Time.parse("2002-03-14 00:19:48") | ||
|
||
#updated_on | ||
should: %s raise_error(Whois::PropertyNotSupported) | ||
|
||
#expires_on | ||
should: %s CLASS(time) | ||
should: %s == Time.parse("2013-03-14 00:19:00") | ||
|
||
|
||
#registrar | ||
should: %s CLASS(registrar) | ||
should: %s.id == nil | ||
should: %s.name == "Register.com" | ||
should: %s.url == "http://www.register.com/" | ||
|
||
|
||
#registrant_contacts | ||
should: %s CLASS(array) | ||
should: %s SIZE(1) | ||
should: %s[0] CLASS(contact) | ||
should: %s[0].type == Whois::Record::Contact::TYPE_REGISTRANT | ||
should: %s[0].name == "Josh Cramer" | ||
should: %s[0].organization == "Cramer Development" | ||
should: %s[0].address == "226 S. Clinton Street" | ||
should: %s[0].city == "Iowa City" | ||
should: %s[0].zip == "52240" | ||
should: %s[0].state == "IA" | ||
should: %s[0].country_code == "US" | ||
should: %s[0].phone == nil | ||
should: %s[0].fax == nil | ||
should: %s[0].email == nil | ||
|
||
#admin_contacts | ||
should: %s CLASS(array) | ||
should: %s SIZE(1) | ||
should: %s[0] CLASS(contact) | ||
should: %s[0].type == Whois::Record::Contact::TYPE_ADMIN | ||
should: %s[0].name == "Host Master" | ||
should: %s[0].organization == "Cramer Development Incorporated" | ||
should: %s[0].address == "226 S Clinton St" | ||
should: %s[0].city == "Iowa City" | ||
should: %s[0].zip == "52245" | ||
should: %s[0].state == "IA" | ||
should: %s[0].country_code == "US" | ||
should: %s[0].phone == "+1.5152920050" | ||
should: %s[0].fax == nil | ||
should: %s[0].email == "domains@cramerdev.com" | ||
|
||
#technical_contacts | ||
should: %s CLASS(array) | ||
should: %s SIZE(1) | ||
should: %s[0] CLASS(contact) | ||
should: %s[0].type == Whois::Record::Contact::TYPE_TECHNICAL | ||
should: %s[0].name == "Host Master" | ||
should: %s[0].organization == "Cramer Development Incorporated" | ||
should: %s[0].address == "226 S Clinton St" | ||
should: %s[0].city == "Iowa City" | ||
should: %s[0].zip == "52245" | ||
should: %s[0].state == "IA" | ||
should: %s[0].country_code == "US" | ||
should: %s[0].phone == "+1.5152920050" | ||
should: %s[0].fax == nil | ||
should: %s[0].email == "domains@cramerdev.com" | ||
|
||
|
||
#nameservers | ||
should: %s CLASS(array) | ||
should: %s SIZE(5) | ||
should: %s[0] CLASS(nameserver) | ||
should: %s[0].name == "dns01.gpn.register.com" | ||
should: %s[1] CLASS(nameserver) | ||
should: %s[1].name == "dns02.gpn.register.com" | ||
should: %s[2] CLASS(nameserver) | ||
should: %s[2].name == "dns03.gpn.register.com" | ||
should: %s[3] CLASS(nameserver) | ||
should: %s[3].name == "dns04.gpn.register.com" | ||
should: %s[4] CLASS(nameserver) | ||
should: %s[4].name == "dns05.gpn.register.com" |
91 changes: 91 additions & 0 deletions
91
spec/fixtures/responses/whois.register.com/status_registered_2.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
|
||
The data in Register.com's WHOIS database is provided to you by | ||
Register.com for information purposes only, that is, to assist you in | ||
obtaining information about or related to a domain name registration | ||
record. Register.com makes this information available "as is," and | ||
does not guarantee its accuracy. By submitting a WHOIS query, you | ||
agree that you will use this data only for lawful purposes and that, | ||
under no circumstances will you use this data to: (1) allow, enable, | ||
or otherwise support the transmission of mass unsolicited, commercial | ||
advertising or solicitations via direct mail, electronic mail, or by | ||
telephone; or (2) enable high volume, automated, electronic processes | ||
that apply to Register.com (or its systems). The compilation, | ||
repackaging, dissemination or other use of this data is expressly | ||
prohibited without the prior written consent of Register.com. | ||
Register.com reserves the right to modify these terms at any time. | ||
By submitting this query, you agree to abide by these terms. | ||
|
||
|
||
=-=-=-= | ||
|
||
|
||
Domain name: cramerdev.com | ||
Is the domain you want taken? Make an offer: http://www.afternic.com/rcom.php?ref_id=2987&name=cramerdev.com | ||
|
||
Registrant Contact: | ||
Cramer Development | ||
Josh Cramer () | ||
|
||
Fax: | ||
226 S. Clinton Street | ||
Iowa City, IA 52240 | ||
US | ||
|
||
Administrative Contact: | ||
Cramer Development Incorporated | ||
Host Master (domains@cramerdev.com) | ||
+1.5152920050 | ||
Fax: | ||
226 S Clinton St | ||
Iowa City, IA 52245 | ||
US | ||
|
||
Technical Contact: | ||
Cramer Development Incorporated | ||
Host Master (domains@cramerdev.com) | ||
+1.5152920050 | ||
Fax: | ||
226 S Clinton St | ||
Iowa City, IA 52245 | ||
US | ||
|
||
Status: Locked | ||
|
||
Name Servers: | ||
dns01.gpn.register.com | ||
dns02.gpn.register.com | ||
dns03.gpn.register.com | ||
dns04.gpn.register.com | ||
dns05.gpn.register.com | ||
|
||
Creation date: 14 Mar 2002 00:19:48 | ||
Expiration date: 14 Mar 2013 00:19:00 | ||
|
||
|
||
|
||
|
||
=-=-=-= | ||
The data in this whois database is provided to you for information | ||
purposes only, that is, to assist you in obtaining information about or | ||
related to a domain name registration record. We make this information | ||
available "as is," and do not guarantee its accuracy. By submitting a | ||
whois query, you agree that you will use this data only for lawful | ||
purposes and that, under no circumstances will you use this data to: (1) | ||
enable high volume, automated, electronic processes that stress or load | ||
this whois database system providing you this information; or (2) allow, | ||
enable, or otherwise support the transmission of mass unsolicited, | ||
commercial advertising or solicitations via direct mail, electronic | ||
mail, or by telephone. The compilation, repackaging, dissemination or | ||
other use of this data is expressly prohibited without prior written | ||
consent from us. | ||
|
||
We reserve the right to modify these terms at any time. By submitting | ||
this query, you agree to abide by these terms. | ||
Version 6.3 4/3/2002 | ||
|
||
|
||
Visit AboutUs.org for more information about cramerdev.com | ||
|
||
<A HREF="http://www.aboutus.org/cramerdev.com">AboutUs: cramerdev.com</A> | ||
|
||
Register your domain name at http://www.register.com |
Oops, something went wrong.