1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-09-19 16:38:51 +02:00
No description
Find a file
epriestley 12722b9ea9 [Wilds] Tailor the behavior of some unit tests which print_r($the_entire_world, true)
Summary:
Ref T13098. I've eventually made `arc unit` at least sort of run, but a few unit tests have an issue under the new code.

We have a couple of cases where we `print_r($stack, true)` or `print_r($exception, true)`, which is effectively the same because exceptions include a stack. In one case, we search in the stack for values to make sure `PhutilOpaqueEnvelope` is really masking secrets. In another case, we just use `print_r(...)` to label test cases, but some test data is exceptions.

Under the new code, the `arc unit` stack has access to a much larger "world" via variables reachable in stack frames, since it's connected to all toolsets/workflows and those objects are more deeply interconnected. This makes the output from `print_r($stack)` enormous and slow (20+ seconds) because of all the recursive referencing of complex variables.

In the case where we're looking at the stack, just print the last couple frames. Also add some positive code that searches for a known value in the stack.

In the case where we're describing variables, just drop the code. We don't really need to label these test cases, the "expect" value is sufficiently clear on its own.

Test Plan: Later, ran `arc unit` and saw it finish in a reasonable amount of time instead of hanging forever on these tests.

Reviewers: amckinley

Reviewed By: amckinley

Maniphest Tasks: T13098

Differential Revision: https://secure.phabricator.com/D19709
2018-09-26 14:15:18 -07:00
bin [Wilds] Rewrite "arc" entrypoints for toolsets 2018-09-21 15:55:08 -07:00
externals [Wilds] Remove include_path mangling and drop support for "externals/includes" 2018-09-21 16:44:11 -07:00
resources [Wilds] Update "arc shell-complete" for toolsets 2018-09-25 16:02:13 -07:00
scripts [Wilds] Allow "arc liberate" to liberate itself again 2018-09-21 16:50:58 -07:00
src [Wilds] Tailor the behavior of some unit tests which print_r($the_entire_world, true) 2018-09-26 14:15:18 -07:00
support [Wilds] Provide a skeleton for prompt behaviors 2018-09-26 14:08:49 -07:00
.arcconfig Set "history.immutable" to "false" explicitly in .arcconfig in Arcanist 2016-08-03 08:13:09 -07:00
.arclint Fold ArcanistPhutilXHPASTLinter into ArcanistXHPASTLinter 2015-11-13 07:08:40 +11:00
.arcunit Rough version of configuration driven unit test engine 2015-08-11 06:54:16 +10:00
.editorconfig Test XHPAST linter rules in isolation 2015-11-19 08:57:23 +11:00
.gitignore [Wilds] Update "arc shell-complete" for toolsets 2018-09-25 16:02:13 -07:00
LICENSE Fix text lint issues 2015-04-07 18:09:27 +10:00
NOTICE Remove duplicate newline 2014-07-17 08:25:22 +10:00
README.md Move README to Markdown 2015-04-13 13:01:16 -07:00

Arcanist is the command-line tool for Phabricator. It allows you to interact with Phabricator installs to send code for review, download patches, transfer files, view status, make API calls, and various other things. You can read more in the User Guide

For more information about Phabricator, see http://phabricator.org/.

LICENSE

Arcanist is released under the Apache 2.0 license except as otherwise noted.