Java Doc for TestPropertiesConfigurationLayout.java in  » Library » Apache-commons-configuration-1.4-src » org » apache » commons » configuration » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Library » Apache commons configuration 1.4 src » org.apache.commons.configuration 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.apache.commons.configuration.TestPropertiesConfigurationLayout

TestPropertiesConfigurationLayout
public class TestPropertiesConfigurationLayout extends TestCase (Code)
Test class for PropertiesConfigurationLayout.
author:
   author:
   href="http://jakarta.apache.org/commons/configuration/team-list.html">Commons
author:
   Configuration team
version:
   $Id: TestPropertiesConfigurationLayout.java 439648 2006-09-02 20:42:10Z oheger $

Inner Class :static class PropertiesBuilder
Inner Class :static class LayoutTestConfiguration extends PropertiesConfiguration

Field Summary
final static  StringCR
     Constant for the line break character.
final static  StringTEST_COMMENT
     Constant for a test comment.
final static  StringTEST_KEY
     Constant for a test property key.
final static  StringTEST_VALUE
     Constant for a test property value.
 PropertiesBuilderbuilder
     A properties builder that can be used for testing.
 LayoutTestConfigurationconfig
     The associated configuration object.
 PropertiesConfigurationLayoutlayout
     The layout object under test.


Method Summary
protected  voidsetUp()
    
public  voidtestBlancLines()
     Tests whether blanc lines before a property are correctly detected.
public  voidtestCombineComments()
     Tests whether comments are combined for multiple occurrences.
public  voidtestEventAdd()
     Tests if a property add event is correctly processed.
public  voidtestEventAddBefore()
     Tests if a before update event is correctly ignored.
public  voidtestEventAddExisting()
     Tests if an add event is correctly processed if the affected property is already stored in the layout object.
public  voidtestEventAddMultiple()
     Tests adding a property multiple time through an event.
public  voidtestEventClearConfig()
     Tests if a clear event is correctly processed.
public  voidtestEventDelete()
     Tests if a property delete event is correctly processed.
public  voidtestEventReload()
     Tests if a reload update is correctly processed.
public  voidtestEventReloadAfter()
     Tests the event after a reload has been performed.
public  voidtestEventSetNonExisting()
     Tests if a set property event for a non existing property is correctly handled.
public  voidtestGetNonExistingLayouData()
     Tests accessing data for a property, which is not stored.
public  voidtestGetNullLayouttData()
     Tests accessing a property with a null key.
public  voidtestHeaderComment()
     Tests if a header comment is detected.
public  voidtestHeaderCommentNull()
     Tests fetching a canonical header comment when no comment is set.
public  voidtestHeaderCommentWithBlancs()
     Tests if a header comment containing blanc lines is correctly detected.
public  voidtestHeaderCommentWithBlancsAndPropComment()
     Tests if a header comment is correctly detected when it contains blanc lines and the first property has a comment, too.
public  voidtestInit()
     Tests a newly created instance.
public  voidtestInitCopy()
     Tests the copy constructor.
public  voidtestInitCopyModify()
     Tests if the copy and the original are independend from each other.
public  voidtestInitNull()
     Tests creating a layout object with a null configuration.
public  voidtestIsSingleLine()
     Tests the single line flag for a simple property definition.
public  voidtestIsSingleLineMulti()
     Tests the single line flag if there are multiple property definitions.
public  voidtestReadAndWrite()
     Tests whether the output of the layout object is identical to the source file (at least for simple properties files).
public  voidtestReadSimple()
     Tests reading a simple properties file.
public  voidtestRecursiveLoadCall()
     Tests a recursive load call.
public  voidtestSave()
     Tests if the content of the layout object is correctly written.
public  voidtestSaveCommentForUnexistingProperty()
     Tests saving when a comment for a non existing property is contained in the layout object.
public  voidtestSaveEmptyLayout()
     Tests saving an empty layout object.
public  voidtestSaveForceSingleLine()
     Tests the force single line flag.
public  voidtestSetNullComment()
     Tests resetting a comment.
public  voidtestTrimComment()
     Tests the trimComment method.
public  voidtestTrimCommentFalse()
     Tests enforcing comment characters in a comment.
public  voidtestTrimCommentTrainlingCR()
     Tests trimming a comment with trailing CRs.

Field Detail
CR
final static String CR(Code)
Constant for the line break character.



TEST_COMMENT
final static String TEST_COMMENT(Code)
Constant for a test comment.



TEST_KEY
final static String TEST_KEY(Code)
Constant for a test property key.



TEST_VALUE
final static String TEST_VALUE(Code)
Constant for a test property value.



builder
PropertiesBuilder builder(Code)
A properties builder that can be used for testing.



config
LayoutTestConfiguration config(Code)
The associated configuration object.



layout
PropertiesConfigurationLayout layout(Code)
The layout object under test.





Method Detail
setUp
protected void setUp() throws Exception(Code)



testBlancLines
public void testBlancLines() throws ConfigurationException(Code)
Tests whether blanc lines before a property are correctly detected.



testCombineComments
public void testCombineComments() throws ConfigurationException(Code)
Tests whether comments are combined for multiple occurrences.



testEventAdd
public void testEventAdd()(Code)
Tests if a property add event is correctly processed.



testEventAddBefore
public void testEventAddBefore()(Code)
Tests if a before update event is correctly ignored.



testEventAddExisting
public void testEventAddExisting() throws ConfigurationException(Code)
Tests if an add event is correctly processed if the affected property is already stored in the layout object.



testEventAddMultiple
public void testEventAddMultiple()(Code)
Tests adding a property multiple time through an event. The property should then be a multi-line property.



testEventClearConfig
public void testEventClearConfig() throws ConfigurationException(Code)
Tests if a clear event is correctly processed.



testEventDelete
public void testEventDelete()(Code)
Tests if a property delete event is correctly processed.



testEventReload
public void testEventReload()(Code)
Tests if a reload update is correctly processed.



testEventReloadAfter
public void testEventReloadAfter()(Code)
Tests the event after a reload has been performed. This should be ignored.



testEventSetNonExisting
public void testEventSetNonExisting()(Code)
Tests if a set property event for a non existing property is correctly handled.



testGetNonExistingLayouData
public void testGetNonExistingLayouData()(Code)
Tests accessing data for a property, which is not stored.



testGetNullLayouttData
public void testGetNullLayouttData()(Code)
Tests accessing a property with a null key. This should throw an exception.



testHeaderComment
public void testHeaderComment() throws ConfigurationException(Code)
Tests if a header comment is detected.



testHeaderCommentNull
public void testHeaderCommentNull()(Code)
Tests fetching a canonical header comment when no comment is set.



testHeaderCommentWithBlancs
public void testHeaderCommentWithBlancs() throws ConfigurationException(Code)
Tests if a header comment containing blanc lines is correctly detected.



testHeaderCommentWithBlancsAndPropComment
public void testHeaderCommentWithBlancsAndPropComment() throws ConfigurationException(Code)
Tests if a header comment is correctly detected when it contains blanc lines and the first property has a comment, too.



testInit
public void testInit()(Code)
Tests a newly created instance.



testInitCopy
public void testInitCopy()(Code)
Tests the copy constructor.



testInitCopyModify
public void testInitCopyModify()(Code)
Tests if the copy and the original are independend from each other.



testInitNull
public void testInitNull()(Code)
Tests creating a layout object with a null configuration. This should cause an exception.



testIsSingleLine
public void testIsSingleLine() throws ConfigurationException(Code)
Tests the single line flag for a simple property definition.



testIsSingleLineMulti
public void testIsSingleLineMulti() throws ConfigurationException(Code)
Tests the single line flag if there are multiple property definitions.



testReadAndWrite
public void testReadAndWrite() throws ConfigurationException(Code)
Tests whether the output of the layout object is identical to the source file (at least for simple properties files).



testReadSimple
public void testReadSimple() throws ConfigurationException(Code)
Tests reading a simple properties file.



testRecursiveLoadCall
public void testRecursiveLoadCall() throws ConfigurationException(Code)
Tests a recursive load call.



testSave
public void testSave() throws ConfigurationException(Code)
Tests if the content of the layout object is correctly written.



testSaveCommentForUnexistingProperty
public void testSaveCommentForUnexistingProperty() throws ConfigurationException(Code)
Tests saving when a comment for a non existing property is contained in the layout object. This comment should be ignored.



testSaveEmptyLayout
public void testSaveEmptyLayout() throws ConfigurationException(Code)
Tests saving an empty layout object.



testSaveForceSingleLine
public void testSaveForceSingleLine() throws ConfigurationException(Code)
Tests the force single line flag.



testSetNullComment
public void testSetNullComment()(Code)
Tests resetting a comment.



testTrimComment
public void testTrimComment()(Code)
Tests the trimComment method.



testTrimCommentFalse
public void testTrimCommentFalse()(Code)
Tests enforcing comment characters in a comment.



testTrimCommentTrainlingCR
public void testTrimCommentTrainlingCR()(Code)
Tests trimming a comment with trailing CRs.



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.