|
Groovy example source code file (OverridePropertyGetterTest.groovy)
The Groovy OverridePropertyGetterTest.groovy source code
package groovy
/**
* test to ensure that overriding getter doesn't throw a NPE on access
*
* @author <a href="mailto:jeremy.rayner@bigfoot.com">Jeremy Rayner
* @version $Revision: 4996 $
*/
class OverridePropertyGetterTest extends GroovyTestCase {
def cheese
void testSimpleMethodParameterAccess() {
def o = new OverridePropertyGetterTest()
def p = new OverridePropertyGetterTest()
try {
//@todo
//p.cheese = o.cheese
} catch (Exception e) {
fail(e.getMessage())
}
}
public String getCheese() {
return cheese
}
}
Other Groovy examples (source code examples)Here is a short list of links related to this Groovy OverridePropertyGetterTest.groovy source code file: |
Other websites by Alvin Alexander:
Life/living in Alaska (OneMansAlaska.com)
How I Sold My Business (HowISoldMyBusiness.com)
Copyright 1998-2011 Alvin Alexander, devdaily.com
All Rights Reserved.