nest 3.1.0 → 3.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/lib/nest.rb +8 -0
  3. data/nest.gemspec +1 -1
  4. data/test/nest_test.rb +10 -0
  5. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c49bcf993beed343e77ec05ed5de6f61c086ca50
4
- data.tar.gz: f1e5d402a830ca77e80cff1d7e448a17764e4854
3
+ metadata.gz: 4c4c4aeff5206eb5114db89a069fbc03d2be990f
4
+ data.tar.gz: 17d53051af21384b2e806057a632ff3a0aea9e0f
5
5
  SHA512:
6
- metadata.gz: 3b4e63709cbd146285e53bf7f8bb657d61c783d3f1eb76e7518cec8715fa49ebdeb508fe18dd339e9929bfd9adab21bd978b8ecee2d34fadd9c4302866998c71
7
- data.tar.gz: 3ca06dff375b45e9277cc08dc75ba6d6aa068db3f581dc831e80f7c73174138a914bff9c5bbde139916f6f82bffe03a3f89d01bbc8db35f3e4a888bc3773012a
6
+ metadata.gz: 7f15b661917706692398bf84b70827ed514a328a9c62e578ff15d4837f3d8216058ae224292452f216d4be1f40a37df94b28874c28cbb8a6db0fa6b72593398d
7
+ data.tar.gz: ace8ba7d6cc84c30b4424b16e46eced592b6a7e436925d75555ed83ca40edd1566b14f73fba421782427aa8fe6e77a8bce5c17ccb321639f1377a26ea38488a2
@@ -42,6 +42,14 @@ class Nest
42
42
  @ns
43
43
  end
44
44
 
45
+ def to_ary
46
+ nil
47
+ end
48
+
49
+ def to_a
50
+ nil
51
+ end
52
+
45
53
  def call(command, *args)
46
54
  @rc.call(command, to_s, *args)
47
55
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "nest"
3
- s.version = "3.1.0"
3
+ s.version = "3.1.1"
4
4
  s.summary = "Object-oriented keys for Redis."
5
5
  s.description = "It is a design pattern in key-value databases to use the key to simulate structure, and Nest can take care of that."
6
6
  s.license = "MIT"
@@ -77,3 +77,13 @@ scope do
77
77
  assert "s1" == n1.get
78
78
  end
79
79
  end
80
+
81
+ # Operations that call to_a and to_ary
82
+ scope do
83
+ test "interaction with array-casting operations" do
84
+ n1 = Nest.new("foo")
85
+
86
+ assert_equal [n1], [n1].flatten
87
+ assert_equal [n1], Array(n1)
88
+ end
89
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nest
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michel Martens
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-15 00:00:00.000000000 Z
11
+ date: 2017-04-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: redic