kapnismology 1.2.0 → 1.3.0
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.
- checksums.yaml +4 -4
- data/README.md +12 -0
- data/lib/kapnismology/evaluation.rb +5 -1
- data/lib/kapnismology/result.rb +12 -0
- data/lib/kapnismology/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: fadb67885456f40120baf78b978ef156e428ec03
|
4
|
+
data.tar.gz: 5b14571e2df67b33387ee38a6fb585563a0baf0b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9da6e31cd9da8f4c9a89321afcccfa5ecfb2059cbb01ef51632325dfd21e376785953e970d99fecf601f0cdaa18644475fdbb650dd4fce7a6c12eb3536970314
|
7
|
+
data.tar.gz: 628969468c630490b3ffce6b86d6bca1ac35ee2db3148e53f60f180eafee6b401c910315715cdb0c359e1482f4a36269ecc790fc750c656912a6690af084e10f
|
data/README.md
CHANGED
@@ -54,6 +54,18 @@ If for any reason you want to have your test in any other location, then you wil
|
|
54
54
|
If you want to change the name of the test, define `self.name` in your
|
55
55
|
smoke test class.
|
56
56
|
|
57
|
+
## Not runnable tests
|
58
|
+
|
59
|
+
If your test find a situation when it does not make sense, then you can return a `Kapnismology::UnTestableResult` instead of a `Kapnismology::Result`. Like:
|
60
|
+
```
|
61
|
+
if (File.exist?('that file'))
|
62
|
+
Result.new(....)
|
63
|
+
else
|
64
|
+
UnTestableResult.new
|
65
|
+
end
|
66
|
+
```
|
67
|
+
|
68
|
+
UnTestableResult do not need any parameter.
|
57
69
|
|
58
70
|
## Tagging and running tags
|
59
71
|
|
data/lib/kapnismology/result.rb
CHANGED
@@ -23,4 +23,16 @@ module Kapnismology
|
|
23
23
|
{ passed: passed?, data: @data, message: @message }
|
24
24
|
end
|
25
25
|
end
|
26
|
+
|
27
|
+
# Use this class when your test is not valid in the current situation
|
28
|
+
# For instance when you have a test for deployments that have not happen, etc.
|
29
|
+
class UnTestableResult
|
30
|
+
attr_reader :message
|
31
|
+
def initialize(message = 'The result could not tested')
|
32
|
+
@message = message
|
33
|
+
end
|
34
|
+
def passed?
|
35
|
+
true
|
36
|
+
end
|
37
|
+
end
|
26
38
|
end
|
data/lib/kapnismology/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kapnismology
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jordi Polo Carres
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02
|
11
|
+
date: 2016-03-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|