[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[cdt-test-dev] RE: [cdt-patch] Bug 69114 - [Managed Build] fails when starting build with old plugin
|
Leo, Sean,
This might be of help in keeping this sort
of thing from happening again. A few months ago I wrote some JUnit tests
to validate the plugin.xml of my managed build toolchain definition. I
actually generate the plugin automatically from an XML description of our
compiler options, so I wanted a good way of making sure that the generated XML
is good. It parses the plugin manifest and checks for duplicate IDs,
validates the parent/child hierarchy, etc.
I hadn’t planned on contributing it
yet but it seems like it would be of use, so have at it :-) It could use
some cleanup e.g. a couple of the classes have a TI naming convention, as does
the plugin name. It’s also got Xerces bundled in it (unmodified),
so I’m not sure if that needs to be exorcised. It would be nicer if
the thing worked on the manifest file “in place” too, rather than
you having to put an “output.xml” file into the tests plugin for
testing, although that wouldn’t be hard if you implement getFileInPlugin(IPath
path) in your plugin.
It needs a bit of fixing too. I had
a nice feature in there that I stole from the PDE that validated my ManagedBuildInfo
extension as per the extension point schema. This worked fantastically
until I merged in CDT 2.0.2, and then for whatever reason it can no longer find
the org.eclipse.cdt.managedbuilder.core plugin. I thought maybe this was
some timing issue whereby the managedbuilder.core plugin wasn’t being
instantiated prior to my JUnit plugin. That doesn’t seem to be the
case though, as if I call a method in the core plugin in my own plugin’s SetUp()
method, it doesn’t help. If anyone can help in figuring this
problem out it would be greatly appreciated :-)
___________________________________________
Chris Recoskie
Texas Instruments, Toronto
-----Original Message-----
From: cdt-patch-admin@xxxxxxxxxxx
[mailto:cdt-patch-admin@xxxxxxxxxxx] On
Behalf Of Treggiari, Leo
Sent: Monday,
November 22, 2004 9:31 AM
To: cdt-patch@xxxxxxxxxxx
Subject: [cdt-patch] Bug 69114 -
[Managed Build] fails when starting build with old plugin
The patch contains a fix for Bug 69114. The particular
problem was that the manifest file contained an invalid id in an optionCategory
“owner” attribute. The patch contains a change to all
appropriate resolveReferences methods to check for unresolved references and
write out an error message. For the optionCategory “owner”
attribute, the “owner” is set to the Tool by default.
Leo Treggiari
|
Attachment:
com.ti.goldenrod.tests.zip
Description: com.ti.goldenrod.tests.zip