flipsasser/addressabler — pull request #2 by JeanMertz (2013-04-04 23:31:31+00:00)
Title: Add option to specify custom TLDs

This PR makes it possible to specify custom TLDs, which don't officially exist, but can be used in private environments.

One use case would be intranets with specific host files, allowing for company TLDs (like `intranet.disney`). In my case, the use-case would be a development environment where I use the `dev` TLD locally.

You can specify custom TLDs like so:

```ruby
Addressable::URI.custom_tlds = {
'dev' => {}
}
```

There was one unrelated spec failing (even on master). I left it untouched. The new specs all pass.

Failing spec is:

```
1) Addressabler should support adding nested values to the query
Failure/Error: uri.query_hash[:foo] = {:bar => "baz", :sommat => [:else, 1, true, false]}
TypeError:
Can't convert Hash into String.
```