Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [ajdt-dev] fixed addProjectTask problem


Good find!

> The fix uses
> org.eclipse.ajdt.internal.builder.Builder.getLastBuildTarget() to get the
> current project.  Could someone verify that this is the best way?


Yep, that's good... we often use AspectJPlugin.getCurrentProject() to get the project, but in this case the last built one is exactly right.

> We need to cover messages in AJDT with unit tests.

Agreed, and we also need to cover a lot more of the base functions too - our unit test suite such as it is leaves a lot to be desired at the moment. We've got a task for fixing this on the list.

-- Adrian
Adrian_Colyer@xxxxxxxxxx



"Mik Kersten" <beatmik@xxxxxxx>
Sent by: ajdt-dev-admin@xxxxxxxxxxxxxxx

01/06/2003 05:01
Please respond to ajdt-dev

       
        To:        <ajdt-dev@xxxxxxxxxxx>
        cc:        <aspectj-dev@xxxxxxxxxxx>
        Subject:        [ajdt-dev] fixed addProjectTask problem



I investigated the high priority bug of build config file errors not showing
up in AJDT.  The problem turned out to be a bit more serious, as it looks
like AJDT has always failed to show all messages given to
org.aspectj.ajde.TaskListManager.addProjectTask(..).  In other words
messages not associated with a single source file.  You may ask yourself why
problems parsing a config file are not associated with that file.  That's a
good question, and a lower priority problem that needs addressing later (it
will always be clear which file was used for the build).

I've fixed this bug by changing
org.eclipse.ajdt.internal.ui.ajde.CompilerMonitor.showMessages() to handle
messages with a null source location, and add those as markers on the
project.   The fix uses
org.eclipse.ajdt.internal.builder.Builder.getLastBuildTarget() to get the
current project.  Could someone verify that this is the best way?

On the AspectJ side, I changed the build config parser error text messages
to make it clear where those errors were coming from
(org.aspectj.util.ConfigParser and org.aspectj.ajdt.ajcBuildArgParser).  

We need to cover messages in AJDT with unit tests.  In AJDE/AJBrowser this
is currently done by running a test that has the tester visually verify that
a message showed up, and click the appropriate button (blah).  Hopefully in
AJDT we can query the task list view for its items and compare.

Mik

--
http://kerstens.org/mik


_______________________________________________
ajdt-dev mailing list
ajdt-dev@xxxxxxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/ajdt-dev


Back to the top