Logo: Relish

  1. Sign in

Project: My-project

Creating templates

Template can be added to the platform so later when objects that hang off platform is created
the prototypical approach can be taken where the values in the template are used to create
the new entity. This feature is an infrastructre concept where it will be used when Platform is created.

Scenarios
Adding a Template

Adds a single template to the platform root.

Given
a :request_to_create_a_realm_template is made for version "1" for "Join Template To Platform"
And
a :platform already exists in the application
When
the request is received
Then
the :realm_template object is created and is returned as a hash via the response object
Adding many Template

Adds many templates at the same time to platform root

Given
a :request_to_create_realm_template_and_base_user_template is made for version "1" for "Join Template To Platform"
And
a :platform already exists in the application
When
the request is received
Then
the :realm_template object is created and is returned as a hash via the response object
And
the :base_user_template object is created and is returned as a hash via the response object
Adding a single Template that is already a child of Platform

This is a fail scenario where the template we are adding has the same use, state and is a default as another template
that is already a child of Platform.

Given
a :request_to_create_a_realm_template is made for version "1" for "Join Template to Platform"
And
the :platform_with_a_default_realm_template exists in the application
When
the request is received
Then
a Data::Exception::BusinessRuleException is raised with the message "Conflict Rule Violation: Template cannot collaborate with Platform because it conflicts with one or more of its children" via the response object

Last published almost 5 years ago by nbeagley.