Skip to content

Commit 05079b9

Browse files
bump version, test for primary key inheritance
1 parent 7ab96ca commit 05079b9

File tree

3 files changed

+30
-1
lines changed

3 files changed

+30
-1
lines changed

CHANGELOG

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
== 4.1.2
2+
* Fixes two bugs related to inheritance: one regarding ActiveRel classes and relationship types, the other regarding ActiveNode primary_key properties not being set when a model is loaded prior to Neo4j session.
3+
4+
== 4.1.1
5+
* Switches use of Fixnum to Integer to improve 32-bit support
6+
17
== 4.1.0
28
This release includes many performance fixes and new features. The most notable:
39
* Huge stylist cleanup/refactoring by Brian on the entire gem by Brian armed with Rubocop. See http://neo4jrb.io/blog/2014/12/29/stay-out-of-trouble.html.

lib/neo4j/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module Neo4j
2-
VERSION = '4.1.1'
2+
VERSION = '4.1.2'
33
end

spec/e2e/id_property_spec.rb

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,5 +327,28 @@ class Apple < Fruit; end
327327
it 'works without conf specified' do
328328
expect(IdProp::Apple.create.my_id).not_to be_nil
329329
end
330+
331+
context 'when a session is not started' do
332+
it 'waits until the session is loaded, then sets id property' do
333+
Neo4j::Session.current.close
334+
335+
module IdProp
336+
class Executive
337+
include Neo4j::ActiveNode
338+
id_property :my_id, on: :my_method
339+
340+
def my_method
341+
'an id'
342+
end
343+
end
344+
345+
class CEO < Executive; end
346+
end
347+
348+
expect(IdProp::CEO.primary_key).to be_nil
349+
create_session
350+
expect(IdProp::CEO.primary_key).not_to be_nil
351+
end
352+
end
330353
end
331354
end

0 commit comments

Comments
 (0)