zeta 2.0.0 → 2.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 47f60c0ee448ee11011042fffc5c328eae4cf2e9
4
- data.tar.gz: 3eafa5921581ce99f5ea7fd2851b00e5aaab726e
3
+ metadata.gz: 43d01ffd8d89df42706ebca59c2c6680520ff9f9
4
+ data.tar.gz: a5646e2a0a345f0b7d995e0afa68b5c6343e68e5
5
5
  SHA512:
6
- metadata.gz: 6474b5bba1b5e951e7fac340b36a1070ed05ed11a37da1980071793593ded3474e1ba9d0f8972c4c0dd64efe78d65d1a5243aefc513dabc68281f488106b66db
7
- data.tar.gz: 601bd12199a7fa1758a0fcd1883e525d16703d9b5775f5b37a5bbbafdb1dc4bfd236f7285113e7bdbc0b120f50c9b743d85ac5f4977f4958effe0cc7111a0d63
6
+ metadata.gz: bbd3ec86f080ee494c8f24c841c800f1a3c5c72764ac1c7cf50b47cfd53d5462f8afd7ad3ef2f0d40612373dc9f8e8afc9d35b5eb5b480c426a6fd6a79ab72a4
7
+ data.tar.gz: b25a68595c253e78169abc30973db1752667e4caea62a2df18fbf8c46909d6e1f105cee369a10930454efbe7ec494e25301a7c7151c31a33922c2c484c99a436
data/CHANGELOG.markdown CHANGED
@@ -1,3 +1,6 @@
1
+ # 2.1.0
2
+ - Bump lacerda to 2.1.0 (fix rspec reporter, allow to validate internal objects)
3
+ - Add `zeta/rspec/autorun_all` to replace `Zeta::RSpec.run`
1
4
  # 2.0.0
2
5
  - Update to lacerda 2.0: adds enum support and raises parsing errors instead of silently returning an empty contract
3
6
 
data/README.md CHANGED
@@ -238,8 +238,11 @@ Of course you'll want to have your infrastructure checked in CI. If you're using
238
238
  ```ruby
239
239
  require_relative 'spec_helper'
240
240
 
241
- require 'zeta/rspec'
242
- Zeta::RSpec.run
241
+ # It will try to fetch the contracts from github and it's a bit slow,
242
+ # so you probably just want to run this in CI
243
+ if ENV['CI']
244
+ require 'zeta/rspec/autorun_all'
245
+ end
243
246
  ```
244
247
 
245
- This will do the same as a `zeta -e test full_check` would do on the command line, but reporting to RSpec instead of printing its output directly. Whether or not you run `Zeta::RSpec.update_contracts` is up to you - perhaps you have HTTP requests disabled in your test suite, or you don't want to be network dependant for every run. If you remove it, however, make sure you run `zeta -e test fetch_remote_contracts` often enough to not be outdated.
248
+ This will try to guess your credentials and do the same as a `zeta -e test full_check` would do on the command line, but reporting to RSpec instead of printing its output directly. Whether or not you run `Zeta::RSpec.update_contracts` is up to you - perhaps you have HTTP requests disabled in your test suite, or you don't want to be network dependant for every run. If you remove it, however, make sure you run `zeta -e test fetch_remote_contracts` often enough to not be outdated.
@@ -0,0 +1,27 @@
1
+ require 'lacerda/reporters/rspec'
2
+ require 'zeta'
3
+
4
+ if defined?(Rails) && ENV['ZETA_HTTP_USER'].blank? && ENV['ZETA_HTTP_PASSWORD'].blank?
5
+ ENV['ZETA_HTTP_USER'] = Rails.application.config_for(:zeta)['user']
6
+ ENV['ZETA_HTTP_PASSWORD'] = Rails.application.config_for(:zeta)['api_key']
7
+ end
8
+
9
+ RSpec.describe "Zeta infrastructure", order: :defined do
10
+ it "has a correctly configured current service" do
11
+ expect{
12
+ Zeta.config
13
+ Zeta.infrastructure
14
+ }.to_not raise_error
15
+ end
16
+
17
+ it "can download the infrastructure contracts (requires network connection)" do
18
+ expect{
19
+ Zeta.verbose = false
20
+ Zeta.update_contracts
21
+ }.to_not raise_error
22
+ end
23
+
24
+ it "has a valid infrastructure" do
25
+ expect(Zeta.contracts_fulfilled?(Lacerda::Reporters::RSpec.new)).to eq true
26
+ end
27
+ end
data/lib/zeta/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  class Zeta
2
- VERSION = "2.0.0"
2
+ VERSION = "2.1.0"
3
3
  end
data/zeta.gemspec CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
  spec.require_paths = ['lib']
20
20
 
21
21
  spec.add_runtime_dependency 'rake'
22
- spec.add_runtime_dependency 'lacerda', '>= 2.0.0'
22
+ spec.add_runtime_dependency 'lacerda', '>= 2.1'
23
23
  spec.add_runtime_dependency 'activesupport'
24
24
  spec.add_runtime_dependency 'httparty'
25
25
  spec.add_runtime_dependency 'colorize'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zeta
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jannis Hermanns
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-21 00:00:00.000000000 Z
11
+ date: 2017-08-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: 2.0.0
33
+ version: '2.1'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: 2.0.0
40
+ version: '2.1'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: activesupport
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -172,6 +172,7 @@ files:
172
172
  - lib/zeta/instance.rb
173
173
  - lib/zeta/local_or_remote_file.rb
174
174
  - lib/zeta/rspec.rb
175
+ - lib/zeta/rspec/autorun_all.rb
175
176
  - lib/zeta/runner.rb
176
177
  - lib/zeta/version.rb
177
178
  - zeta.gemspec