stellar-base 0.0.14 → 0.0.15
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/lib/stellar/account_flags.rb +1 -1
- data/lib/stellar/base/version.rb +1 -1
- data/spec/lib/stellar/account_flags_spec.rb +19 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e177f7099ce8a48b3e1b3c2376647563ed4460b3
|
4
|
+
data.tar.gz: f4cbbd3ae2ae21e5d35d1cffc8eb65fb7f611d58
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 35b56daffab1e769f3b0ff5259a303f82e0d4ffaaf7272853d98026653f8e0a9da695a027434026758e6cdd44468ff7a1c50a5e47a621a60930f1b97a0f8c3e7
|
7
|
+
data.tar.gz: 67a831ead3527468d5cdf104e806c6c987dd241be0179c61a3e9b891e571017f4cc2576e52d7ee22501edefb851453108f41aa9237842263ef4fb48b77fbafe5
|
data/lib/stellar/base/version.rb
CHANGED
@@ -0,0 +1,19 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Stellar::AccountFlags do
|
4
|
+
subject{ Stellar::AccountFlags }
|
5
|
+
let(:raw) { 3 }
|
6
|
+
let(:result) { subject.parse_mask raw }
|
7
|
+
|
8
|
+
it "parses correctly" do
|
9
|
+
expect(subject.parse_mask(1)).to eq([Stellar::AccountFlags.auth_required_flag])
|
10
|
+
expect(subject.parse_mask(2)).to eq([Stellar::AccountFlags.auth_revocable_flag])
|
11
|
+
expect(subject.parse_mask(3)).to eq([Stellar::AccountFlags.auth_required_flag, Stellar::AccountFlags.auth_revocable_flag])
|
12
|
+
end
|
13
|
+
|
14
|
+
it "makes correctly" do
|
15
|
+
expect(subject.make_mask([Stellar::AccountFlags.auth_required_flag])).to eq(1)
|
16
|
+
expect(subject.make_mask([Stellar::AccountFlags.auth_revocable_flag])).to eq(2)
|
17
|
+
expect(subject.make_mask([Stellar::AccountFlags.auth_required_flag, Stellar::AccountFlags.auth_revocable_flag])).to eq(3)
|
18
|
+
end
|
19
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stellar-base
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Scott Fleckenstein
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: xdr
|
@@ -323,6 +323,7 @@ files:
|
|
323
323
|
- lib/stellar/util/base58.rb
|
324
324
|
- lib/stellar/util/continued_fraction.rb
|
325
325
|
- ruby-stellar-base.gemspec
|
326
|
+
- spec/lib/stellar/account_flags_spec.rb
|
326
327
|
- spec/lib/stellar/convert_spec.rb
|
327
328
|
- spec/lib/stellar/key_pair_spec.rb
|
328
329
|
- spec/lib/stellar/price_spec.rb
|
@@ -370,6 +371,7 @@ signing_key:
|
|
370
371
|
specification_version: 4
|
371
372
|
summary: 'Stellar client library: XDR'
|
372
373
|
test_files:
|
374
|
+
- spec/lib/stellar/account_flags_spec.rb
|
373
375
|
- spec/lib/stellar/convert_spec.rb
|
374
376
|
- spec/lib/stellar/key_pair_spec.rb
|
375
377
|
- spec/lib/stellar/price_spec.rb
|