r_spec 1.0.0.beta9 → 1.0.0.beta10

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 (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +10 -2
  3. data/lib/r_spec.rb +54 -0
  4. metadata +4 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6599635e0de35bec4d9bae9f58ab1417a364eb2a0bd64db49b523be4d9ab1d16
4
- data.tar.gz: 658671a666d8173ce075558dc7dc0f5604e2a98f86e0448485c2ad713ec518be
3
+ metadata.gz: ba07a04820e5602fb73f32e7b265ef6cc755a54c396a7c9419fc97c8125d2fb1
4
+ data.tar.gz: 2330fe89b377b2f0cf13aaf6d325bf0b4f1c1fff5a409b8feba2f24f39e040a2
5
5
  SHA512:
6
- metadata.gz: 45babe5acbed804ce1a61476c39028cdaa46256c343b0b6001b83e0bd5cda35a83770bd06776c7b76d22cb0dd3cbc07be7978d30d99c04cc1585e9cdeb933778
7
- data.tar.gz: 78f72312fc8c2ad764647a1e6698f4a094bfc3129c0b2911f809502ba9a11d9a0da88ffafc2420c68d55fdaeeb8062258e8ff738013bded1bcf1970f536f192d
6
+ metadata.gz: 76a062afb51273f181f86db0fd85eb342fe6404f832e6facba450607f32f6b8555057ffa9918379ae30a8a63548c0911378348318ddba64be5bf94a14ecad8c1
7
+ data.tar.gz: 0d90f7fd0f0b94f40d28d4cb4c6dfcf82047830067881b0a8fef8108eb8cf4704b1542589023d91aed0f3814bbc10a5b7652269ac67ab7477a8a1c2231dc3383
data/README.md CHANGED
@@ -7,7 +7,7 @@ A minimalist __[RSpec](https://github.com/rspec/rspec) clone__ with all the esse
7
7
  ## Status
8
8
 
9
9
  [![Gem Version](https://badge.fury.io/rb/r_spec.svg)](https://badge.fury.io/rb/r_spec)
10
- [![Build Status](https://travis-ci.org/cyril/r_spec.rb.svg?branch=main)](https://travis-ci.org/cyril/r_spec.rb)
10
+ [![CI](https://github.com/cyril/r_spec.rb/workflows/ci/badge.svg?branch=main)](https://github.com/cyril/r_spec.rb/actions?query=workflow%3Aci+branch%3Amain)
11
11
  [![Documentation](https://img.shields.io/:yard-docs-38c800.svg)](https://rubydoc.info/gems/r_spec/frames)
12
12
 
13
13
  ## Project goals
@@ -47,7 +47,7 @@ Following [RubyGems naming conventions](https://guides.rubygems.org/name-your-ge
47
47
  Add this line to your application's Gemfile:
48
48
 
49
49
  ```ruby
50
- gem "r_spec", ">= 1.0.0.beta9"
50
+ gem "r_spec", ">= 1.0.0.beta10"
51
51
  ```
52
52
 
53
53
  And then execute:
@@ -257,3 +257,11 @@ __RSpec clone__ follows [Semantic Versioning 2.0](https://semver.org/).
257
257
  ## License
258
258
 
259
259
  The [gem](https://rubygems.org/gems/r_spec) is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
260
+
261
+ ## One more thing
262
+
263
+ Under the hood, __RSpec clone__ is largely animated by [a collection of testing libraries designed to make programmers happy](https://github.com/fixrb/).
264
+
265
+ It's a living example of what we can do combining small libraries together that can boost the fun of programming.
266
+
267
+ ![Fix testing tools logo for Ruby](https://github.com/cyril/r_spec.rb/raw/main/img/fixrb.svg)
data/lib/r_spec.rb CHANGED
@@ -74,4 +74,58 @@ module RSpec
74
74
  def self.describe(const, &block)
75
75
  Dsl.describe(const, &block)
76
76
  end
77
+
78
+ # Defines a concrete test case.
79
+ #
80
+ # The test is performed by the block supplied to &block.
81
+ #
82
+ # @example The integer after 41
83
+ # require "r_spec"
84
+ #
85
+ # RSpec.it { expect(41.next).to be 42 }
86
+ #
87
+ # # Output to the console
88
+ # # Success: expected to be 42.
89
+ #
90
+ # It is usually used inside a {Dsl.describe} or {Dsl.context} section.
91
+ #
92
+ # @param name [String, nil] The name of the spec.
93
+ # @param block [Proc] An expectation to evaluate.
94
+ #
95
+ # @raise (see RSpec::ExpectationTarget::Base#result)
96
+ # @return (see RSpec::ExpectationTarget::Base#result)
97
+ #
98
+ # @api public
99
+ def self.it(name = nil, &block)
100
+ Dsl.it(name, &block)
101
+ end
102
+
103
+ # Defines a pending test case.
104
+ #
105
+ # `&block` is never evaluated. It can be used to describe behaviour that is
106
+ # not yet implemented.
107
+ #
108
+ # @example
109
+ # require "r_spec"
110
+ #
111
+ # RSpec.pending "is implemented but waiting" do
112
+ # expect something to be finished
113
+ # end
114
+ #
115
+ # RSpec.pending "is not yet implemented and waiting"
116
+ #
117
+ # # Output to the console
118
+ # # Warning: is implemented but waiting.
119
+ # # Warning: is not yet implemented and waiting.
120
+ #
121
+ # It is usually used inside a {Dsl.describe} or {Dsl.context} section.
122
+ #
123
+ # @param message [String] The reason why the example is pending.
124
+ #
125
+ # @return [nil] Write a message to STDOUT.
126
+ #
127
+ # @api public
128
+ def self.pending(message)
129
+ Dsl.pending(message)
130
+ end
77
131
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: r_spec
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.beta9
4
+ version: 1.0.0.beta10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cyril Kato
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-19 00:00:00.000000000 Z
11
+ date: 2021-06-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: expresenter
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 1.0.0
47
+ version: 1.1.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 1.0.0
54
+ version: 1.1.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: bundler
57
57
  requirement: !ruby/object:Gem::Requirement