seiten 1.3.0 → 1.3.1

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.
@@ -44,6 +44,13 @@ class Seiten::PageCollectionTest < ActiveSupport::TestCase
44
44
  assert_nil page_collection.find_by(id: 2, parent_id: 2)
45
45
  end
46
46
 
47
+ test '#find_by does not keep what it did not find' do
48
+ page_collection.find_by(id: 1)
49
+ page_collection.find_by(slug: 'wp-admin')
50
+
51
+ assert_equal [{ id: 1 }], page_collection.instance_variable_get(:@find_by).keys
52
+ end
53
+
47
54
  test '#where' do
48
55
  assert_equal [1], page_collection.where(id: 1).map(&:id)
49
56
  assert_equal [2,3], page_collection.where(parent_id: 1).map(&:id)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: seiten
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Puglisi