given_core 3.3.0.beta1 → 3.3.0.beta2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/Rakefile +7 -0
- data/lib/given/evaluator.rb +11 -1
- data/lib/given/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 350c16f9d05805f55dd27ce321f1a90ed120ce62
|
4
|
+
data.tar.gz: 827b657fb53d44f407dcdcd11c1ee411bc604ead
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: daa7c5d7762814b46877fef0511dc732bfc0e181460109404cb31c736ecabf9414f40986d2c12c1f47c803efd467d724baac175644c938c6798872abe836da53
|
7
|
+
data.tar.gz: 90867ec7fb14a86b40cda51665e488c1558bc5d1c6a807f9a981ca13143c7465ef66f364d2941a7094e261dcad56b58b0828b45372517f652c90e473735e33ac
|
data/README.md
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
| :----: |
|
5
5
|
| [![Master Build Status](https://secure.travis-ci.org/jimweirich/rspec-given.png?branch=master)](https://travis-ci.org/jimweirich/rspec-given) |
|
6
6
|
|
7
|
-
Covering rspec-given, minitest-given, and given-core, version 3.3.0.
|
7
|
+
Covering rspec-given, minitest-given, and given-core, version 3.3.0.beta21.
|
8
8
|
|
9
9
|
rspec-given and minitest-given are extensions to your favorite testing
|
10
10
|
framework to allow Given/When/Then notation when writing specs.
|
data/Rakefile
CHANGED
@@ -41,6 +41,13 @@ task :tag do
|
|
41
41
|
sh "git tag #{tag_name}"
|
42
42
|
end
|
43
43
|
|
44
|
+
desc "Publish the gems"
|
45
|
+
task :publish => [:clobber, :gem] do
|
46
|
+
FileList['pkg/*.gem'].each do |gemname|
|
47
|
+
sh "gem push #{gemname}"
|
48
|
+
end
|
49
|
+
end
|
50
|
+
|
44
51
|
# Running examples ---------------------------------------------------
|
45
52
|
|
46
53
|
desc "Run all the examples"
|
data/lib/given/evaluator.rb
CHANGED
@@ -22,7 +22,7 @@ module Given
|
|
22
22
|
end
|
23
23
|
|
24
24
|
def eval_string(exp_string)
|
25
|
-
eval_in_context(exp_string).inspect
|
25
|
+
limit_length(eval_in_context(exp_string).inspect)
|
26
26
|
rescue StandardError => ex
|
27
27
|
EvalErr.new("#{ex.class}: #{ex.message}")
|
28
28
|
end
|
@@ -33,6 +33,16 @@ module Given
|
|
33
33
|
|
34
34
|
private
|
35
35
|
|
36
|
+
MAX_INSPECT_SIZE = 2000
|
37
|
+
|
38
|
+
def limit_length(string)
|
39
|
+
if string.size > MAX_INSPECT_SIZE
|
40
|
+
string[0..MAX_INSPECT_SIZE] + " (...truncated...)"
|
41
|
+
else
|
42
|
+
string
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
36
46
|
def eval_in_context(exp_string)
|
37
47
|
exp_proc = "proc { #{exp_string} }"
|
38
48
|
blk = eval(exp_proc, @block.binding)
|
data/lib/given/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: given_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.3.0.
|
4
|
+
version: 3.3.0.beta2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jim Weirich
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-12-
|
11
|
+
date: 2013-12-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sorcerer
|