Difference between revisions of "OtfTemplates"
(Created page with "{{DISPLAYTITLE:Open Test Framework - OTX Templates}}Category:OTF ==Overview== OTX templates are very similar to the templates found in MS OfficeWord. They can be used for...") |
|||
Line 14: | Line 14: | ||
The following section describes the creation of a user defined template step-by-step. | The following section describes the creation of a user defined template step-by-step. | ||
# Create a project in OTF with the structure you want. Please note, that the all elements of this project will be copied later as it is into a new element (Project, Document or Procedure). | # Create a project in OTF with the structure you want. Please note, that the all elements of this project will be copied later as it is into a new element (Project, Document or Procedure). | ||
− | # Save this project as a PTX. Please note, that a PTX is only a ZIP archive | + | # Save this project as a PTX. Please note, that a PTX is only a ZIP archive with a special content file (index.xml) |
# Copy this PTX to the OTF template folder [ProgramData]/emotive/Open Test Framework/Templates/ and rename the extension to "*.ptxt". Inside this folder you will find the Default.ptxt. This is the default template of the OTF for new Projects, Documents or Procedures. Changing this template will effect all new elements inside the OTF. | # Copy this PTX to the OTF template folder [ProgramData]/emotive/Open Test Framework/Templates/ and rename the extension to "*.ptxt". Inside this folder you will find the Default.ptxt. This is the default template of the OTF for new Projects, Documents or Procedures. Changing this template will effect all new elements inside the OTF. | ||
− | # | + | # Copy the whole folder "TemplateSettings" from Default.ptxt inside your new created template. |
# Look for the file "OtfTemplateConfig.xml" inside that folder and adapt it to your requirements. You will find an annotated schema ("OtfTemplateConfig.xsd") inside the folder, which describes the structure of the settings file.</xsd:documentation> | # Look for the file "OtfTemplateConfig.xml" inside that folder and adapt it to your requirements. You will find an annotated schema ("OtfTemplateConfig.xsd") inside the folder, which describes the structure of the settings file.</xsd:documentation> | ||
Revision as of 12:17, 26 November 2014
Overview
OTX templates are very similar to the templates found in MS OfficeWord. They can be used for a quick and easy creation of user specific structured projects, documents and/or procedures. Templates can contain placeholders. A placeholder can be located inside OTX documents, in file names (document) and folder names (package).
Storage location
The OTX templates are stored in the folder
[ProgramData]/emotive/Open Test Framework/Templates/
The file Default.ptxt is the OTF default template. All new projects, documents and procedures are based at this template. In other words, if this template was changed, the content of the new projects, documents and procedures will also changed.
Step by step creation
The following section describes the creation of a user defined template step-by-step.
- Create a project in OTF with the structure you want. Please note, that the all elements of this project will be copied later as it is into a new element (Project, Document or Procedure).
- Save this project as a PTX. Please note, that a PTX is only a ZIP archive with a special content file (index.xml)
- Copy this PTX to the OTF template folder [ProgramData]/emotive/Open Test Framework/Templates/ and rename the extension to "*.ptxt". Inside this folder you will find the Default.ptxt. This is the default template of the OTF for new Projects, Documents or Procedures. Changing this template will effect all new elements inside the OTF.
- Copy the whole folder "TemplateSettings" from Default.ptxt inside your new created template.
- Look for the file "OtfTemplateConfig.xml" inside that folder and adapt it to your requirements. You will find an annotated schema ("OtfTemplateConfig.xsd") inside the folder, which describes the structure of the settings file.</xsd:documentation>
Placeholder
During applying of a template all placeholders will be replaced with the corresponding values. The placeholder has the following format:
~~id_67576d3026a84070b9b656d62172f559~~
A placeholder can exist in each OTX files at any place and also in the name of the files and folders. Only file names and folder names below the OTX folder (in the PTX) will be replaced. A placeholder can be formatted inside the template settings file "OtfTemplateConfig.xml". You will find an annotated schema ("OtfTemplateConfig.xsd") inside the folder, which describes the structure of the settings file.