Sha256: c23ccc7bd860322bbb1f043242919fb082caf98d1c302edb04a20186188a5e21

Contents?: true

Size: 737 Bytes

Versions: 2

Compression:

Stored size: 737 Bytes

Contents

Feature: Update cached attributes after saving the parent record

  Scenario:
    Given model "Author" exists with attributes:
      | attribute | type   |
      | name      | string |
    And model "Book" exists with attributes:
      | attribute   | type    |
      | title       | string  |
      | author_id   | integer |
      | author_name | string  |
    And Book cached_belongs_to Author with cached: "name"
    And Author has many Books
    And a Author exists:
      | name | John Mellencamp |
    And a Book exists:
      | title | Treasure Island |
    And that Book belongs to that Author
    When I change the Author's name to "Deeprak Chopa"
    And I save the Author
    Then Book's author name should be "Deeprak Chopa"

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cached_belongs_to-0.0.2 features/update_cached_attributes_after_save_parent_record.feature
cached_belongs_to-0.0.1 features/update_cached_attributes_after_save_parent_record.feature