This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 221409 - Identifying definition content type fails when WTP is installed
Summary: Identifying definition content type fails when WTP is installed
Status: NEW
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Cosmos (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P2 major (vote)
Target Milestone: ---   Edit
Assignee: David Whiteman CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-04 16:23 EST by David Whiteman CLA
Modified: 2012-01-03 13:46 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Whiteman CLA 2008-03-04 16:23:45 EST
When you have the WTP project installed, our content type checker fails to identify a "definition" type, because WTP has its own content type for XSD files.  I guess we need to introspect the contents of the schema to determine whether it's SML or just plain XML.

Here's the stack trace of the failed JUnit:

junit.framework.AssertionFailedError: The file does not have the correct content type expected:<org.eclipse.cosmos.rm.validation.definitionContentType> but was:<org.eclipse.wst.xsd.core.xsdsource>
	at junit.framework.Assert.fail(Assert.java:47)
	at junit.framework.Assert.failNotEquals(Assert.java:280)
	at junit.framework.Assert.assertEquals(Assert.java:64)
	at org.eclipse.cosmos.rm.validation.internal.common.TestContentTypes.testContentDescriber(TestContentTypes.java:106)
	at org.eclipse.cosmos.rm.validation.internal.common.TestContentTypes.testDefinitionContentType(TestContentTypes.java:90)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:615)
	at junit.framework.TestCase.runTest(TestCase.java:164)
	at junit.framework.TestCase.runBare(TestCase.java:130)
	at junit.framework.TestResult$1.protect(TestResult.java:106)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.framework.TestResult.run(TestResult.java:109)
	at junit.framework.TestCase.run(TestCase.java:120)
	at org.eclipse.hyades.test.common.junit.HyadesTestCase.run(HyadesTestCase.java:172)
	at junit.framework.TestSuite.runTest(TestSuite.java:230)
	at org.eclipse.hyades.test.common.junit.HyadesTestSuite.runTest(HyadesTestSuite.java:457)
	at junit.framework.TestSuite.run(TestSuite.java:225)
	at org.eclipse.hyades.test.common.junit.HyadesTestSuite.doRun(HyadesTestSuite.java:425)
	at org.eclipse.hyades.test.common.junit.HyadesTestSuite.run(HyadesTestSuite.java:338)
	at org.eclipse.hyades.test.common.junit.HyadesTestRunner.run(HyadesTestRunner.java:504)
	at org.eclipse.tptp.test.tools.junit.plugin.runner.PluginJobRunner.access$0(PluginJobRunner.java:1)
	at org.eclipse.tptp.test.tools.junit.plugin.runner.PluginJobRunner$1.run(PluginJobRunner.java:39)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Comment 1 David Whiteman CLA 2008-03-04 16:29:21 EST
This is more important than before, due to the WTP prereq introduced by the data manager toolkit.
Comment 2 David Whiteman CLA 2008-04-22 13:12:29 EDT
still a problem in i10 candidate build, so it causes one of the tests in TestContentTypes plugin test to fail