firstclasspostcodes 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. checksums.yaml +7 -0
  2. data/.dependabot/config.yml +12 -0
  3. data/.github/workflows/gem.yml +53 -0
  4. data/.gitignore +9 -0
  5. data/.rspec +2 -0
  6. data/.rubocop.yml +78 -0
  7. data/Gemfile +25 -0
  8. data/LICENSE +21 -0
  9. data/Rakefile +11 -0
  10. data/firstclasspostcodes.gemspec +54 -0
  11. data/lib/firstclasspostcodes.rb +33 -0
  12. data/lib/firstclasspostcodes/client.rb +81 -0
  13. data/lib/firstclasspostcodes/configuration.rb +156 -0
  14. data/lib/firstclasspostcodes/events.rb +27 -0
  15. data/lib/firstclasspostcodes/operations.rb +4 -0
  16. data/lib/firstclasspostcodes/operations/get_lookup.rb +52 -0
  17. data/lib/firstclasspostcodes/operations/get_postcode.rb +40 -0
  18. data/lib/firstclasspostcodes/operations/methods/format_address.rb +38 -0
  19. data/lib/firstclasspostcodes/operations/methods/list_addresses.rb +29 -0
  20. data/lib/firstclasspostcodes/response_error.rb +29 -0
  21. data/lib/firstclasspostcodes/version.rb +5 -0
  22. data/spec/firstclasspostcodes/client_spec.rb +94 -0
  23. data/spec/firstclasspostcodes/events_spec.rb +41 -0
  24. data/spec/firstclasspostcodes/operations/get_lookup_spec.rb +103 -0
  25. data/spec/firstclasspostcodes/operations/get_postcode_spec.rb +58 -0
  26. data/spec/firstclasspostcodes/operations/methods/format_address_spec.rb +106 -0
  27. data/spec/firstclasspostcodes/operations/methods/list_addresses_spec.rb +75 -0
  28. data/spec/firstclasspostcodes/response_error_spec.rb +43 -0
  29. data/spec/firstclasspostcodes/version_spec.rb +9 -0
  30. data/spec/firstclasspostcodes_spec.rb +108 -0
  31. data/spec/spec_helper.rb +42 -0
  32. data/spec/support/events_examples.rb +11 -0
  33. metadata +123 -0
@@ -0,0 +1,11 @@
1
+ # frozen_string_literal: true
2
+
3
+ RSpec.shared_examples "a class that emits events" do
4
+ specify { expect(subject).to respond_to(:on) }
5
+
6
+ specify { expect(subject).to respond_to(:off) }
7
+
8
+ specify { expect(subject).to respond_to(:emit) }
9
+
10
+ specify { expect(subject).to respond_to(:events) }
11
+ end
metadata ADDED
@@ -0,0 +1,123 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: firstclasspostcodes
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Firstclasspostcodes
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2020-01-18 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: json
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 2.2.0
20
+ - - "~>"
21
+ - !ruby/object:Gem::Version
22
+ version: '2.2'
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: 2.2.0
30
+ - - "~>"
31
+ - !ruby/object:Gem::Version
32
+ version: '2.2'
33
+ - !ruby/object:Gem::Dependency
34
+ name: typhoeus
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '1.3'
40
+ - - ">="
41
+ - !ruby/object:Gem::Version
42
+ version: 1.3.1
43
+ type: :runtime
44
+ prerelease: false
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "~>"
48
+ - !ruby/object:Gem::Version
49
+ version: '1.3'
50
+ - - ">="
51
+ - !ruby/object:Gem::Version
52
+ version: 1.3.1
53
+ description: |2
54
+ With 500 requests for free per month, get started with the
55
+ fastest and cheapest address lookup service in the UK.
56
+
57
+ See https://firstclasspostcodes.com for more details.
58
+ email: support@firstclasspostcodes.com
59
+ executables: []
60
+ extensions: []
61
+ extra_rdoc_files: []
62
+ files:
63
+ - ".dependabot/config.yml"
64
+ - ".github/workflows/gem.yml"
65
+ - ".gitignore"
66
+ - ".rspec"
67
+ - ".rubocop.yml"
68
+ - Gemfile
69
+ - LICENSE
70
+ - Rakefile
71
+ - firstclasspostcodes.gemspec
72
+ - lib/firstclasspostcodes.rb
73
+ - lib/firstclasspostcodes/client.rb
74
+ - lib/firstclasspostcodes/configuration.rb
75
+ - lib/firstclasspostcodes/events.rb
76
+ - lib/firstclasspostcodes/operations.rb
77
+ - lib/firstclasspostcodes/operations/get_lookup.rb
78
+ - lib/firstclasspostcodes/operations/get_postcode.rb
79
+ - lib/firstclasspostcodes/operations/methods/format_address.rb
80
+ - lib/firstclasspostcodes/operations/methods/list_addresses.rb
81
+ - lib/firstclasspostcodes/response_error.rb
82
+ - lib/firstclasspostcodes/version.rb
83
+ - spec/firstclasspostcodes/client_spec.rb
84
+ - spec/firstclasspostcodes/events_spec.rb
85
+ - spec/firstclasspostcodes/operations/get_lookup_spec.rb
86
+ - spec/firstclasspostcodes/operations/get_postcode_spec.rb
87
+ - spec/firstclasspostcodes/operations/methods/format_address_spec.rb
88
+ - spec/firstclasspostcodes/operations/methods/list_addresses_spec.rb
89
+ - spec/firstclasspostcodes/response_error_spec.rb
90
+ - spec/firstclasspostcodes/version_spec.rb
91
+ - spec/firstclasspostcodes_spec.rb
92
+ - spec/spec_helper.rb
93
+ - spec/support/events_examples.rb
94
+ homepage: https://docs.firstclasspostcodes.com
95
+ licenses:
96
+ - MIT
97
+ metadata:
98
+ bug_tracker_uri: https://github.com/firstclasspostcodes/firstclasspostcodes-ruby/issues
99
+ changelog_uri: https://github.com/firstclasspostcodes/firstclasspostcodes-ruby/blob/master/CHANGELOG.md
100
+ documentation_uri: https://docs.firstclasspostcodes.com
101
+ github_repo: ssh://github.com/firstclasspostcodes/firstclasspostcodes-ruby
102
+ homepage_uri: https://firstclasspostcodes.com
103
+ source_code_uri: https://github.com/firstclasspostcodes/firstclasspostcodes-ruby
104
+ post_install_message:
105
+ rdoc_options: []
106
+ require_paths:
107
+ - lib
108
+ required_ruby_version: !ruby/object:Gem::Requirement
109
+ requirements:
110
+ - - ">="
111
+ - !ruby/object:Gem::Version
112
+ version: 2.3.0
113
+ required_rubygems_version: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ requirements: []
119
+ rubygems_version: 3.0.3
120
+ signing_key:
121
+ specification_version: 4
122
+ summary: Ruby bindings for the Firstclasspostcodes API
123
+ test_files: []