Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 356816

Summary: [AbstrDeclValidator] internal state turns bogus
Product: [Modeling] TMF Reporter: Moritz Eysholdt <moritz.eysholdt>
Component: XtextAssignee: Project Inbox <tmf.xtext-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3    
Version: 2.0.1   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:

Description Moritz Eysholdt CLA 2011-09-06 10:01:05 EDT
When first running 
ValidattionTester.validate()
and then 
IResourceValidator.validate()
IllegalStateException("State is already assigned.") will be thrown.

proposed fix:
reset AbstractDeclarativeValidator.state from within ValidationTester.diagnose(). 
The protocol of ValidationTester suggests that diagnose() is called after validate() has been called. AbstractDeclarativeValidator will need to provide a method to reset its state, since state is currently an internal implementation detail.