| Summary: | reassigning doesn't work with Bugzilla 3.1 | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Albert Ting <altlist> | ||||||||||||
| Component: | Mylyn | Assignee: | Frank Becker <eclipse> | ||||||||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||||||||
| Severity: | normal | ||||||||||||||
| Priority: | P5 | CC: | robert.elves | ||||||||||||
| Version: | unspecified | Keywords: | helpwanted | ||||||||||||
| Target Milestone: | --- | ||||||||||||||
| Hardware: | All | ||||||||||||||
| OS: | All | ||||||||||||||
| Whiteboard: | |||||||||||||||
| Attachments: |
|
||||||||||||||
|
Description
Albert Ting
Bugzilla 3.1 stream isn't currently supported but we will need to resolve this at some point. We could take a contribution if anyone is interested. Hi I work on this and have now the question. How can I detected the Bugzilla version from BugzillaTaskEditor, this should be used to generate two ways to generate the peopleLayout. Created attachment 76397 [details]
mylyn/context/zip
Created attachment 76485 [details]
patch with fix for Bugzilla 3.1
Please see if this can be used as a fix for this bug
Created attachment 76486 [details]
mylyn/context/zip
(In reply to comment #3) > How can I detected the Bugzilla version from BugzillaTaskEditor, this should be > used to generate two ways to generate the peopleLayout. Sorry I didn't get back to you sooner Frank. Looks like you found your way to the repository configuration for the version though. ;) When you post a patch, we've been adding the [patch] label to the beginning of the summary. By doing this your patch will get attention sooner. Patch is looking good. Only problem I found were the changes to BugzillaTaskDataHandler. This effectively drops the reassign capability (at least for < 3.1 repositories). Reassigning to you Frank... (In reply to comment #7) > (In reply to comment #3) > > How can I detected the Bugzilla version from BugzillaTaskEditor, this should be > > used to generate two ways to generate the peopleLayout. > > Sorry I didn't get back to you sooner Frank. Looks like you found your way to > the repository configuration for the version though. ;) > > When you post a patch, we've been adding the [patch] label to the beginning of > the summary. By doing this your patch will get attention sooner. > > Patch is looking good. Only problem I found were the changes to > BugzillaTaskDataHandler. This effectively drops the reassign capability (at > least for < 3.1 repositories). You are right. It is my mistake, I forgot to look how I get the repository version within BugzillaTaskDataHandler. Actually I must go to work (it is morning in germany). I look at this, but this will not be before 11 pm today. > > Reassigning to you Frank... > Created attachment 76605 [details]
correted Patch
Here is the corrected Patch.
BTW here some questiones
Do I need to add some JUnit Tests?
Is it OK that I only add a JavaDoc in AbstractRepositoryTaskEditor.java for addAssignedTo?
Is BugzillaCorePlugin.getRepositoryConfiguration(repository, false).getInstallVersion() the right way to test the Bugzilla Version?
Created attachment 76606 [details]
mylyn/context/zip
Great. Patch applied, ip log updated. Verified against 3.0 but unable to test against 3.1 here. (In reply to comment #9) > Do I need to add some JUnit Tests? Yes, this is a perfect example of a patch that should ideally be accompanied with a unit test. It would test bug reassignment against both mylyn.eclipse.org/bugs222 and mylyn.eclipse.org/bugs31 (the latter doesn't exist yet though since we don't officially support 3.1). Ideally all patches should come with a unit test with the exception of some ui related code that can be tricky to test (although we can usually find a way). > Is it OK that I only add a JavaDoc in AbstractRepositoryTaskEditor.java for > addAssignedTo? Yes, documenting new public api is good. > Is BugzillaCorePlugin.getRepositoryConfiguration(repository, > false).getInstallVersion() the right way to test the Bugzilla Version? Yes, though note that this could block if the configuration hasn't yet been retrieved so needs to be used with that in mind. By the time the editor is opening the configuration would have been retrieved. Worst case scenario here is they don't have a configuration and the editor takes an unusually long time to open. > (In reply to comment #9)
> > Do I need to add some JUnit Tests?
> Yes, this is a perfect example of a patch that should ideally be accompanied
> with a unit test. It would test bug reassignment against both
> mylyn.eclipse.org/bugs222 and mylyn.eclipse.org/bugs31 (the latter doesn't exist
> yet though since we don't officially support 3.1).
>
This is the first time I create an JUnit test.
So please tell me in which JUnitfile a find an good starting example for do the test with mylyn.eclipse.org/bugs222.
See BugzillaRepositoryConnectorTest, you could append your tests there. (In reply to comment #13) > See BugzillaRepositoryConnectorTest, you could append your tests there. Sorry I have some questions: Should I create an new bug in the testbugzilla and how is this done(can't fond code for this) Is it allowed to submit a new bug with every the test run You can just pick a more recently created bug report that isn't already being used by automated tests and use it for reassign tests. This test may be a bit tricky to write though since you may need to use two accounts (so you can reassign it back). We may want to hold off on this until we have a 3.1 repository setup as well. |