sibit 0.6.0 → 0.7.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
  SHA256:
3
- metadata.gz: bffdfd4fc0e852f5e78e27ce795d452f8d73b2e19af8b6d7f0c568a981b042b9
4
- data.tar.gz: ab3d76f7ffa5d2773c969d74a707cc713a0a91b6f23f79827a8bb860dffd71a4
3
+ metadata.gz: ca6545ba86de32ef32e697433524c11c8b563757cb8de20dc23093df29597ba5
4
+ data.tar.gz: a711ec74da8e12b4791d09733df3f058d574cea2baef1959060099999c336932
5
5
  SHA512:
6
- metadata.gz: bcf1082248a88d3d497957e7433a20b9ebb2ac66ee75136390ff8d28aef8082e2a8bbdc8f1ef766fb17b30835e3215c35128c3146ba24ad25788b3cac0519f6f
7
- data.tar.gz: 41a43a40203b84dc78021a671993abfd5d5e9ed2ff502cc3891d8c4040b4b8d409fcbc9e6fa17ed71c69fdc66e3a78dee92ea72d199eee1ffc6def2b0097951b
6
+ metadata.gz: 5e4ee0809688604f0e9202fb15d7f68da9afaa8f2944d938d42c65c745afe28395dddc907073cd63f25d81ea7866a77f5ec92234557bacdeaf4a0ebff44e7f98
7
+ data.tar.gz: 396b574af7310831460c0ef6248002f9a3d5a493ee879ce1252ede5827f3e1a527e138dc93cdd7dbda2d91fec1a1103bd61484e18955d64764c09737f89e9333
data/features/cli.feature CHANGED
@@ -6,6 +6,14 @@ Feature: Command Line Processing
6
6
  Then Exit code is zero
7
7
  And Stdout contains "--help"
8
8
 
9
+ Scenario: Bitcoin price can be retrieved
10
+ When I run bin/sibit with "price"
11
+ Then Exit code is zero
12
+
13
+ Scenario: Bitcoin latest block hash can be retrieved
14
+ When I run bin/sibit with "latest"
15
+ Then Exit code is zero
16
+
9
17
  Scenario: Bitcoin private key can be generated
10
18
  When I run bin/sibit with "generate"
11
19
  Then Exit code is zero
data/lib/sibit/version.rb CHANGED
@@ -26,5 +26,5 @@
26
26
  # License:: MIT
27
27
  class Sibit
28
28
  # Current version of the library.
29
- VERSION = '0.6.0'
29
+ VERSION = '0.7.0'
30
30
  end
data/lib/sibit.rb CHANGED
@@ -37,6 +37,37 @@ class Sibit
37
37
  # If something goes wrong.
38
38
  class Error < StandardError; end
39
39
 
40
+ # Fake one, which is useful for testing.
41
+ class Fake
42
+ def price(_cur = 'USD')
43
+ 4_000
44
+ end
45
+
46
+ def generate
47
+ 'fd2333686f49d8647e1ce8d5ef39c304520b08f3c756b67068b30a3db217dcb2'
48
+ end
49
+
50
+ def create(_pvt)
51
+ '1JvCsJtLmCxEk7ddZFnVkGXpr9uhxZPmJi'
52
+ end
53
+
54
+ def balance(_address)
55
+ 100_000_000
56
+ end
57
+
58
+ def pay(_amount, _fee, _sources, _target, _change)
59
+ '9dfe55a30b5ee732005158c589179a398117117a68d21531fb6c78b85b544c54'
60
+ end
61
+
62
+ def latest
63
+ '00000000000000000008df8a6e1b61d1136803ac9791b8725235c9f780b4ed71'
64
+ end
65
+
66
+ def get_json(_uri)
67
+ {}
68
+ end
69
+ end
70
+
40
71
  # Constructor.
41
72
  #
42
73
  # You may provide the log you want to see the messages in. If you don't
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sibit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-11 00:00:00.000000000 Z
11
+ date: 2019-04-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: backtrace