Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15390442
D13868.id33495.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
8 KB
Referenced Files
None
Subscribers
None
D13868.id33495.diff
View Options
diff --git a/src/lint/engine/ArcanistLintEngine.php b/src/lint/engine/ArcanistLintEngine.php
--- a/src/lint/engine/ArcanistLintEngine.php
+++ b/src/lint/engine/ArcanistLintEngine.php
@@ -57,7 +57,6 @@
private $changedLines = array();
private $enableAsyncLint = false;
- private $postponedLinters = array();
private $configurationManager;
private $linterResources = array();
@@ -403,15 +402,6 @@
return array($line, $char);
}
- final public function getPostponedLinters() {
- return $this->postponedLinters;
- }
-
- final public function setPostponedLinters(array $linters) {
- $this->postponedLinters = $linters;
- return $this;
- }
-
protected function getCacheVersion() {
return 1;
}
diff --git a/src/unit/ArcanistUnitTestResult.php b/src/unit/ArcanistUnitTestResult.php
--- a/src/unit/ArcanistUnitTestResult.php
+++ b/src/unit/ArcanistUnitTestResult.php
@@ -10,7 +10,6 @@
const RESULT_SKIP = 'skip';
const RESULT_BROKEN = 'broken';
const RESULT_UNSOUND = 'unsound';
- const RESULT_POSTPONED = 'postponed';
private $namespace;
private $name;
diff --git a/src/unit/renderer/ArcanistUnitConsoleRenderer.php b/src/unit/renderer/ArcanistUnitConsoleRenderer.php
--- a/src/unit/renderer/ArcanistUnitConsoleRenderer.php
+++ b/src/unit/renderer/ArcanistUnitConsoleRenderer.php
@@ -28,13 +28,6 @@
return $return;
}
- public function renderPostponedResult($count) {
- return sprintf(
- "%s %s\n",
- $this->getFormattedResult(ArcanistUnitTestResult::RESULT_POSTPONED),
- pht('%d test(s)', $count));
- }
-
private function getFormattedResult($result) {
switch ($result) {
case ArcanistUnitTestResult::RESULT_PASS:
@@ -54,11 +47,6 @@
'<bg:yellow>** %s **</bg>',
pht('UNSOUND'));
- case ArcanistUnitTestResult::RESULT_POSTPONED:
- return phutil_console_format(
- '<bg:yellow>** %s **</bg>',
- pht('POSTPONED'));
-
default:
return null;
}
diff --git a/src/unit/renderer/ArcanistUnitRenderer.php b/src/unit/renderer/ArcanistUnitRenderer.php
--- a/src/unit/renderer/ArcanistUnitRenderer.php
+++ b/src/unit/renderer/ArcanistUnitRenderer.php
@@ -2,5 +2,4 @@
abstract class ArcanistUnitRenderer extends Phobject {
abstract public function renderUnitResult(ArcanistUnitTestResult $result);
- abstract public function renderPostponedResult($count);
}
diff --git a/src/workflow/ArcanistDiffWorkflow.php b/src/workflow/ArcanistDiffWorkflow.php
--- a/src/workflow/ArcanistDiffWorkflow.php
+++ b/src/workflow/ArcanistDiffWorkflow.php
@@ -17,7 +17,6 @@
private $testResults;
private $diffID;
private $revisionID;
- private $postponedLinters;
private $haveUncommittedChanges = false;
private $diffPropertyFutures = array();
private $commitMessageFromRevision;
@@ -476,7 +475,6 @@
$lint_result = $data['lintResult'];
$this->unresolvedLint = $data['unresolvedLint'];
- $this->postponedLinters = $data['postponedLinters'];
$unit_result = $data['unitResult'];
$this->testResults = $data['testResults'];
@@ -1222,7 +1220,6 @@
return array(
'lintResult' => $lint_result,
'unresolvedLint' => $this->unresolvedLint,
- 'postponedLinters' => $this->postponedLinters,
'unitResult' => $unit_result,
'testResults' => $this->testResults,
);
@@ -1290,12 +1287,6 @@
pht('Lint issued unresolved errors!'),
'lint-excuses');
break;
- case ArcanistLintWorkflow::RESULT_POSTPONED:
- $this->console->writeOut(
- "<bg:yellow>** %s **</bg> %s\n",
- pht('LINT POSTPONED'),
- pht('Lint results are postponed.'));
- break;
}
$this->unresolvedLint = array();
@@ -1303,8 +1294,6 @@
$this->unresolvedLint[] = $message->toDictionary();
}
- $this->postponedLinters = $lint_workflow->getPostponedLinters();
-
return $lint_result;
} catch (ArcanistNoEngineException $ex) {
$this->console->writeOut(
@@ -2260,7 +2249,6 @@
ArcanistLintWorkflow::RESULT_ERRORS => 'fail',
ArcanistLintWorkflow::RESULT_WARNINGS => 'warn',
ArcanistLintWorkflow::RESULT_SKIP => 'skip',
- ArcanistLintWorkflow::RESULT_POSTPONED => 'postponed',
);
return idx($map, $lint_result, 'none');
}
@@ -2275,7 +2263,6 @@
ArcanistUnitWorkflow::RESULT_FAIL => 'fail',
ArcanistUnitWorkflow::RESULT_UNSOUND => 'warn',
ArcanistUnitWorkflow::RESULT_SKIP => 'skip',
- ArcanistUnitWorkflow::RESULT_POSTPONED => 'postponed',
);
return idx($map, $unit_result, 'none');
}
diff --git a/src/workflow/ArcanistLintWorkflow.php b/src/workflow/ArcanistLintWorkflow.php
--- a/src/workflow/ArcanistLintWorkflow.php
+++ b/src/workflow/ArcanistLintWorkflow.php
@@ -9,7 +9,6 @@
const RESULT_WARNINGS = 1;
const RESULT_ERRORS = 2;
const RESULT_SKIP = 3;
- const RESULT_POSTPONED = 4;
const DEFAULT_SEVERITY = ArcanistLintSeverity::SEVERITY_ADVICE;
@@ -19,7 +18,6 @@
private $shouldAmendWithoutPrompt = false;
private $shouldAmendAutofixesWithoutPrompt = false;
private $engine;
- private $postponedLinters;
public function getWorkflowName() {
return 'lint';
@@ -399,12 +397,6 @@
}
}
- // It'd be nice to just return a single result from the run method above
- // which contains both the lint messages and the postponed linters.
- // However, to maintain compatibility with existing lint subclasses, use
- // a separate method call to grab the postponed linters.
- $this->postponedLinters = $engine->getPostponedLinters();
-
if ($this->getArgument('never-apply-patches')) {
$apply_patches = false;
} else {
@@ -650,8 +642,6 @@
$result_code = self::RESULT_ERRORS;
} else if ($has_warnings) {
$result_code = self::RESULT_WARNINGS;
- } else if (!empty($this->postponedLinters)) {
- $result_code = self::RESULT_POSTPONED;
} else {
$result_code = self::RESULT_OKAY;
}
@@ -669,8 +659,4 @@
return $this->unresolvedMessages;
}
- public function getPostponedLinters() {
- return $this->postponedLinters;
- }
-
}
diff --git a/src/workflow/ArcanistUnitWorkflow.php b/src/workflow/ArcanistUnitWorkflow.php
--- a/src/workflow/ArcanistUnitWorkflow.php
+++ b/src/workflow/ArcanistUnitWorkflow.php
@@ -9,7 +9,6 @@
const RESULT_UNSOUND = 1;
const RESULT_FAIL = 2;
const RESULT_SKIP = 3;
- const RESULT_POSTPONED = 4;
private $unresolvedTests;
private $testResults;
@@ -175,19 +174,13 @@
$unresolved = array();
$coverage = array();
- $postponed_count = 0;
foreach ($results as $result) {
$result_code = $result->getResult();
- if ($result_code == ArcanistUnitTestResult::RESULT_POSTPONED) {
- $postponed_count++;
+ if ($this->engine->shouldEchoTestResults()) {
+ $console->writeOut('%s', $renderer->renderUnitResult($result));
+ }
+ if ($result_code != ArcanistUnitTestResult::RESULT_PASS) {
$unresolved[] = $result;
- } else {
- if ($this->engine->shouldEchoTestResults()) {
- $console->writeOut('%s', $renderer->renderUnitResult($result));
- }
- if ($result_code != ArcanistUnitTestResult::RESULT_PASS) {
- $unresolved[] = $result;
- }
}
if ($result->getCoverage()) {
foreach ($result->getCoverage() as $file => $report) {
@@ -195,11 +188,6 @@
}
}
}
- if ($postponed_count) {
- $console->writeOut(
- '%s',
- $renderer->renderPostponedResult($postponed_count));
- }
if ($coverage) {
$file_coverage = array_fill_keys(
@@ -252,9 +240,6 @@
break;
} else if ($result_code == ArcanistUnitTestResult::RESULT_UNSOUND) {
$overall_result = self::RESULT_UNSOUND;
- } else if ($result_code == ArcanistUnitTestResult::RESULT_POSTPONED &&
- $overall_result != self::RESULT_UNSOUND) {
- $overall_result = self::RESULT_POSTPONED;
}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mar 16 2025, 6:13 AM (5 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7706301
Default Alt Text
D13868.id33495.diff (8 KB)
Attached To
Mode
D13868: Remove leftover code for "postponed" lint and unit status
Attached
Detach File
Event Timeline
Log In to Comment