Facelet Functional Test
Revision as of 19:29, 21 May 2008 by Cameron.bateman.oracle.com
For all these tests, start with a Dynamic Web Project with the JSF 1.2/Facelet facets. Ensure that JSF runtime, JSTL 1.2 and the facelet jars in the classpath. Create an XHTML 1.0 Transitional file in the WebContent root directory.
- Place the cursor inside the html tag.
- Add the text xmlns:f=. Verify that content assist activates after the equals sign.
- With the cursor after the = sign, and Ctrl-Space.
- Verify again the content assist is activated with the following options:
- Select on of the options and verify that it is correctly inserted.
No duplicate insertion
- With one of the namespace options inserted into the HTML from the test above.
- Create a new attribute for xmlns:h=
- Verify that the options list for content assist (which should again appear after entering hitting the = sign) includes all valid namespace options 'except' the one already inserted.
- Select an option and verify that it inserts correctly.
- Create an XHTML document and add the core and html namespaces to the page.
- Save the page.
- Create an opening less-than (<) and hit Ctrl-Space.
- Verify that all the core and html tags are present.
- Select h:form and verify it is correctly inserted.
- Add the text <f: to a document with core declared with the f prefix.
- Hit Ctrl-Space after the : and verify that only the core tags are listed in the content assist.
- Add the text <h:in to a document with html declared with the h prefix.
- Hit Ctrl-Space after the text and verify that only inputHidden, inputSecret, inputText, inputTextarea are present.
Attribute Name Assist
- In a no-attribute h:outputText tag, activate content assist.
- Verify that the attribute options are listed.
- Select value and verify it inserts correctly.
- In an h:message tag, activate content assist for attributes.
- Verify that the attribute for is marked to indicate it is required.\
- Select for and verify it inserts correctly.
Attribute Name Prefix
- In a no-attribute h:outputText tag, add the a v at the beginning of an attribute.
- Activate content assist after the v.
- Verify that only assists for validator, validatorMessage, value, valueChangeListener.
- Select the validator and verify it inserts correctly.