Sha256: 7bdf069cf6bbca77a205aa0a70fec4cc4dd2fedac14f23c74c40382230a7936b
Contents?: true
Size: 1.28 KB
Versions: 1
Compression:
Stored size: 1.28 KB
Contents
Feature: has association Background: Given the default Recliner::Document database is set to "http://localhost:5984/recliner-features" And the database "http://localhost:5984/recliner-features" exists And the following document definitions: """ class User < Recliner::Document end class Article < Recliner::Document has :author end """ Scenario: assigning instance to association Given I have a saved instance of "User" with id "user-1" And I have a saved instance of "Article" with id "article-1" When I set its author to the "User" with id "user-1" Then its "author" should be the "User" with id "user-1" Scenario: assigning id to association Given I have a saved instance of "User" with id "user-1" And I have a saved instance of "Article" with id "article-1" When I set its author_id to "user-1" Then its "author" should be the "User" with id "user-1" Scenario: loading association Given I have a saved instance of "User" with id "user-1" And I have a saved instance of "Article" with attributes: | id | article-1 | | author_id | user-1 | When I load the "Article" instance with id "article-1" Then its "author" should be the "User" with id "user-1"
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
recliner-0.0.1 | features/associations/has.feature |