cardano_wallet 0.1.2 → 0.1.3
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/.github/workflows/nightly.yml +34 -0
- data/.github/workflows/tests.yml +3 -3
- data/README.md +3 -0
- data/Rakefile +10 -0
- data/lib/cardano_wallet/shelley.rb +3 -2
- data/lib/cardano_wallet/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 18f7c7b3b86013c1d54155e315cc55618607d3966fed126a32041f59db989e43
|
4
|
+
data.tar.gz: 327110f84584c66842d1fd2d5fd89e55711a01c5372b93585763f7dac0eb3a19
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 591537d49cd9665a1e162435e6e72e6fe41b2515e47dde9a0894e1593572efcab01fb567879fe3bbc7a75050397fbce1a40b67687b6d7745cccd0be40268ebc9
|
7
|
+
data.tar.gz: 4fe2f473246fafb52bde69d8c85b9140a66fd40bc024a8307dde779fbe291a6a7aa9fa89f396ec3c65c0c47d63eaa457fb5f2db20bea0ad7dda0752f6a225795
|
@@ -0,0 +1,34 @@
|
|
1
|
+
name: Nightly
|
2
|
+
|
3
|
+
on:
|
4
|
+
schedule:
|
5
|
+
- cron: "0 21 * * *"
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
test:
|
9
|
+
|
10
|
+
runs-on: ubuntu-latest
|
11
|
+
|
12
|
+
steps:
|
13
|
+
- uses: actions/checkout@v2
|
14
|
+
- name: Set up cardano-wallet
|
15
|
+
run: NODE_CONFIG_PATH=`pwd`/spec/shelley-testnet docker-compose -f docker-compose-shelley.yml up --detach
|
16
|
+
- name: Set up Ruby
|
17
|
+
# To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
|
18
|
+
# change this to (see https://github.com/ruby/setup-ruby#versioning):
|
19
|
+
# uses: ruby/setup-ruby@v1
|
20
|
+
uses: ruby/setup-ruby@ec106b438a1ff6ff109590de34ddc62c540232e0
|
21
|
+
with:
|
22
|
+
ruby-version: 2.6
|
23
|
+
- name: Install dependencies
|
24
|
+
run: bundle install
|
25
|
+
- name: Wait until node is synced
|
26
|
+
run: bundle exec rake wait_until_node_synced
|
27
|
+
- name: Run all tests
|
28
|
+
run: bundle exec rspec
|
29
|
+
env:
|
30
|
+
CI: true
|
31
|
+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
32
|
+
NETWORK: testnet
|
33
|
+
WALLET: dev-master-shelley
|
34
|
+
NODE: master
|
data/.github/workflows/tests.yml
CHANGED
@@ -31,11 +31,11 @@ jobs:
|
|
31
31
|
ruby-version: 2.6
|
32
32
|
- name: Install dependencies
|
33
33
|
run: bundle install
|
34
|
-
- name: Run tests
|
35
|
-
run: bundle exec
|
34
|
+
- name: Run all tests except nighlty
|
35
|
+
run: bundle exec rspec . -t ~nightly
|
36
36
|
env:
|
37
37
|
CI: true
|
38
38
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
39
39
|
NETWORK: testnet
|
40
40
|
WALLET: dev-master-shelley
|
41
|
-
NODE:
|
41
|
+
NODE: master
|
data/README.md
CHANGED
@@ -11,6 +11,9 @@
|
|
11
11
|
<a href="https://github.com/piotr-iohk/cardano-wallet-rb/actions?query=workflow%3ATests">
|
12
12
|
<img src="https://github.com/piotr-iohk/cardano-wallet-rb/workflows/Tests/badge.svg" />
|
13
13
|
</a>
|
14
|
+
<a href="https://github.com/piotr-iohk/cardano-wallet-rb/actions?query=workflow%3ANightly">
|
15
|
+
<img src="https://github.com/piotr-iohk/cardano-wallet-rb/workflows/Nightly/badge.svg" />
|
16
|
+
</a>
|
14
17
|
|
15
18
|
# cardano-wallet-rb
|
16
19
|
|
data/Rakefile
CHANGED
@@ -4,3 +4,13 @@ require "rspec/core/rake_task"
|
|
4
4
|
RSpec::Core::RakeTask.new(:spec)
|
5
5
|
|
6
6
|
task :default => :spec
|
7
|
+
|
8
|
+
require_relative "lib/cardano_wallet"
|
9
|
+
task :wait_until_node_synced do
|
10
|
+
desc "Wait for node to be synced"
|
11
|
+
network = CardanoWallet.new.misc.network
|
12
|
+
while network.information["sync_progress"]["status"] == "syncing" do
|
13
|
+
puts "Syncing... #{network.information["sync_progress"]["progress"]["quantity"]}%"
|
14
|
+
sleep 15
|
15
|
+
end
|
16
|
+
end
|
@@ -230,8 +230,9 @@ module CardanoWallet
|
|
230
230
|
|
231
231
|
# List all stake pools
|
232
232
|
# @see https://input-output-hk.github.io/cardano-wallet/api/edge/#operation/listStakePools
|
233
|
-
def list(
|
234
|
-
|
233
|
+
def list(stake = {})
|
234
|
+
stake.empty? ? query = '' : query = Utils.to_query(stake)
|
235
|
+
self.class.get("/stake-pools#{query}")
|
235
236
|
end
|
236
237
|
|
237
238
|
# Join stake pool
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cardano_wallet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Piotr Stachyra
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-06-
|
11
|
+
date: 2020-06-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|
@@ -102,6 +102,7 @@ extensions: []
|
|
102
102
|
extra_rdoc_files: []
|
103
103
|
files:
|
104
104
|
- ".github/workflows/gem-push.yml"
|
105
|
+
- ".github/workflows/nightly.yml"
|
105
106
|
- ".github/workflows/tests.yml"
|
106
107
|
- ".gitignore"
|
107
108
|
- ".rakeTasks"
|