Fix hosting service bug tracker configuration and required flags.
Review Request #3140 — Created June 10, 2012 and submitted
Fix hosting service bug tracker configuration and required flags. Bug tracker configuration had some problems when using the hosting service's bug tracker, especially with certain combinations of bug trackers and hosting services. There were two key issues: 1) The bug tracker plan field's required state was based on the selected bug tracker service, but it wasn't taking into account the Use Hosting Service's Bug Tracker state. Now that is factored in. 2) The bug tracker plan's value wasn't being based off the repository plan when using the hosting service's bug tracker. This meant that if you used GitHub as the hosting service, the bug tracker plan was still "default", which didn't exist in the GitHub hosting service's plans. Now that's using the selected hosting service's repository plan. While working on this, I realized that we were doing a lot of work to set the required flags, but never setting them back, which made them appear incorrectly (which could possibly affect validation on future fixes). So now we store the required states and then set them back after validation. To make the unit tests for this not be so time-consuming, I added a flag to turn off the repository validation. This is used in the new test for bug trackers.
New unit tests run, and the repository I was trying to configure now works.