1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-27 04:45:20 +01:00
psalm/tests
Tyson Andre e3d59bf5d4
Support taint detection on Throwable::getTraceAsString() (#3731)
And `__toString()`, which uses getTraceAsString().

Fixes #3696

```php
function login($username, $password, $secret) {
    throw new RuntimeException('login failure');
}
try {
    login('user', $_GET['pass'], SECRET);
} catch (Exception $e) {
    // This output includes unescaped 'pass' and SECRET
    echo $e, "\n";
    echo $e->getTraceAsString();
}
```
2020-07-01 21:27:40 -04:00
..
command_functions
Config Improve handling of array_map, faking out calls where nececssary 2020-06-25 13:05:34 -04:00
EndToEnd Fix things 2020-06-06 11:23:05 -04:00
FileManipulation
FileUpdates Fix another test 2020-05-14 23:56:04 -04:00
fixtures Fix things 2020-06-06 11:23:05 -04:00
Internal/Provider Add more mocking to tests 2020-06-06 16:57:25 -04:00
LanguageServer Fix #3117 - invalidate all caches when composer lockfile changes 2020-04-12 11:41:37 -04:00
Loop Remove unnecesary conditional check for do 2020-05-16 16:32:36 -04:00
Progress
Template Fix #3603 - better typed value comparisons for loose equality 2020-06-18 09:31:38 -04:00
Traits Fix deprecated call 2020-04-03 14:56:11 -04:00
TypeReconciliation Fix tests 2020-06-25 01:33:02 -04:00
AlgebraTest.php Fix a test thing 2020-03-29 19:51:13 -04:00
AnnotationTest.php Fix #3506 - prevent black classes in throws check 2020-06-01 14:56:27 -04:00
ArgTest.php Fix tests 2020-06-11 12:19:34 -04:00
ArrayAccessTest.php Fix #3668 - taint property types for magic properties without @property 2020-06-25 00:24:37 -04:00
ArrayAssignmentTest.php Fix #3720 - allow literal unions in keys to map to object-like arrays 2020-07-01 18:57:19 -04:00
ArrayFunctionCallTest.php Respect possibly-undefined array keys while merging 2020-05-19 20:10:01 -04:00
AssertAnnotationTest.php Allow lists to have their types refined 2020-06-18 10:01:16 -04:00
AssignmentTest.php
BadFormatTest.php
BinaryOperationTest.php Respect possibly-undefined array keys while merging 2020-05-19 20:10:01 -04:00
CallableTest.php Fix #3567 - remember which variables a callable sets byref in use 2020-06-14 11:58:50 -04:00
ClassLoadOrderTest.php
ClassScopeTest.php
ClassStringTest.php Fix #3609 - interpret strings as regular static calls 2020-06-18 11:56:08 -04:00
ClassTest.php
CloneTest.php Fix #3719 - prevent crash when cloning missing class 2020-07-01 10:10:55 -04:00
ClosureTest.php Fix #3268 - infer generator return for closure 2020-04-29 16:52:37 -04:00
CodebaseTest.php
ComposerLockTest.php
ConstantTest.php Infer better types for magic constants used in const initializers (#3602) 2020-06-18 09:48:51 -04:00
DeprecatedAnnotationTest.php
DocblockInheritanceTest.php
DocCommentTest.php Clean up comment parsing 2020-05-28 22:14:41 -04:00
DocumentationTest.php Drop missing issues from XSD schema (#3657) 2020-06-23 16:56:39 -04:00
EnumTest.php
ErrorBaselineTest.php
ExtendsFinalClassTest.php Extending final class is prohibited #3037 (#3576) 2020-06-13 00:29:59 -04:00
FileDiffTest.php
FileReferenceTest.php
ForbiddenCodeTest.php
FunctionCallTest.php Fix handling of coerced callmap args 2020-06-24 11:51:31 -04:00
GeneratorTest.php Fix #3215 - suppress PossiblyUndefinedMethod in synthetic call 2020-04-24 00:11:32 -04:00
ImmutableAnnotationTest.php Fix reconciliation of template param to literal string 2020-06-11 11:58:31 -04:00
IncludeTest.php Get type of requires 2020-06-13 15:48:12 -04:00
InterfaceTest.php
InternalAnnotationTest.php Treat methods of internal or psalm internal classes as internal (#3698) 2020-06-28 13:15:54 -04:00
IssueBufferTest.php
IssueSuppressionTest.php
JsonOutputTest.php Fix tests 2020-05-14 23:22:49 -04:00
junit.xsd
ListTest.php Fix #3289 - treat property on non-generic type like actual value 2020-05-02 23:37:59 -04:00
MagicMethodAnnotationTest.php Fix #3721 - prevent crash on empty @method 2020-07-01 09:00:33 -04:00
MagicPropertyTest.php Fix #3624 - inherit magic property annotations from traits 2020-06-20 16:53:17 -04:00
MethodCallTest.php Fix #3694 - allow two args for PDO::query 2020-06-26 18:26:06 -04:00
MethodMutationTest.php
MethodSignatureTest.php Make Throwable methods overridable (#3203) 2020-04-20 17:17:47 -04:00
MixinAnnotationTest.php Allow static method mixin to invoke instance method 2020-06-20 18:05:35 -04:00
NamespaceTest.php
Php40Test.php
Php55Test.php Consolidate generator tests 2020-04-06 08:57:18 -04:00
Php56Test.php Consolidate generator tests 2020-04-06 08:57:18 -04:00
Php70Test.php Consolidate generator tests 2020-04-06 08:57:18 -04:00
Php71Test.php Suppress new issue 2020-04-19 09:28:53 -04:00
ProjectCheckerTest.php Add more mocking to tests 2020-06-06 16:57:25 -04:00
PropertyTypeTest.php Fix #3642 - detect missing property when name matches 2020-06-23 13:12:46 -04:00
PsalmInternalAnnotationTest.php Treat methods of internal or psalm internal classes as internal (#3698) 2020-06-28 13:15:54 -04:00
PsalmPluginTest.php
PureAnnotationTest.php Fix #3551 - count method can be impure 2020-06-14 11:06:53 -04:00
ReferenceConstraintTest.php Allow updating array by reference 2020-06-15 14:45:08 -04:00
ReportOutputTest.php Fix #3676 - add multiline output for TaintedInput issues 2020-06-30 13:17:51 -04:00
ReturnTypeTest.php Detect never-return statement same as a throw 2020-05-26 15:02:23 -04:00
SelfOutTest.php Add new annotation: @psalm-self-out (#3650) 2020-07-01 18:10:24 -04:00
StubTest.php Fix reset call 2020-06-21 13:03:55 -04:00
SwitchTypeTest.php Improve performance of long switch checks 2020-06-15 16:23:19 -04:00
TaintTest.php Support taint detection on Throwable::getTraceAsString() (#3731) 2020-07-01 21:27:40 -04:00
TestCase.php Add faster taint analysis 2020-05-22 12:33:29 -04:00
TestConfig.php
ThrowsAnnotationTest.php
ThrowsInGlobalScopeTest.php
ToStringTest.php Only cast in echo when tracking taints 2020-06-29 15:06:11 -04:00
TraceTest.php @psalm-trace is now a specific low-level issue, because plain debug print breaks structured output (after #3080) (#3106) 2020-04-08 21:03:05 -04:00
TraitTest.php Fix #3460 - allow isset checks on static properties 2020-05-26 17:40:27 -04:00
TryCatchTest.php Support string class_alias calls with leading backslash 2020-05-27 08:14:47 -04:00
TypeAnnotationTest.php Fix #3532 - expand type alias types recursively 2020-06-07 12:01:04 -04:00
TypeCombinationTest.php Support merging of numeric-string with literal 2020-05-18 16:56:09 -04:00
TypeParseTest.php Fix #3716 - prevent crash for Foo|? return type 2020-06-29 17:52:55 -04:00
UnusedCodeTest.php Fix #3607 - constant string class reference with leading backslash (#3612) 2020-06-19 18:02:39 -04:00
UnusedVariableTest.php Fix #3188 - register global variables as by-reference ones 2020-04-19 13:15:04 -04:00
VariadicTest.php