mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-30 02:32:42 +01:00
Move misplaced validation for ambiguous fields in "Test Plan" to the right place
Summary: When users use the web UI to enter text like "Reviewers: x" into the "Summary" or "Test Plan", we can end up with an ambiguous commit message. Some time ago we added a warning about this to the "Summary" field, and //attempted// to add it to the "Test Plan" field, but it actually gets called from the wrong place. Remove the code from the wrong place (no callers, not reachable) and put it in the right place. This fixes an issue where users could edit a test plan from the web UI to add the text "Tests: ..." and cause ambiguities on a later "arc diff --edit". Test Plan: {F5026603} Reviewers: chad, amckinley Reviewed By: chad Differential Revision: https://secure.phabricator.com/D18175
This commit is contained in:
parent
83266e805c
commit
596b83a712
2 changed files with 4 additions and 8 deletions
|
@ -50,11 +50,4 @@ final class DifferentialTestPlanCommitMessageField
|
|||
);
|
||||
}
|
||||
|
||||
public function validateTransactions($object, array $xactions) {
|
||||
return $this->validateCommitMessageCorpusTransactions(
|
||||
$object,
|
||||
$xactions,
|
||||
pht('Test Plan'));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -55,7 +55,10 @@ final class DifferentialRevisionTestPlanTransaction
|
|||
}
|
||||
|
||||
public function validateTransactions($object, array $xactions) {
|
||||
$errors = array();
|
||||
$errors = $this->validateCommitMessageCorpusTransactions(
|
||||
$object,
|
||||
$xactions,
|
||||
pht('Test Plan'));
|
||||
|
||||
$is_required = PhabricatorEnv::getEnvConfig(
|
||||
'differential.require-test-plan-field');
|
||||
|
|
Loading…
Reference in a new issue