From cf9fbd88c0e266e7bfefd3668fa93f1d2de55870 Mon Sep 17 00:00:00 2001 From: Martin Zurowietz Date: Sun, 4 Jul 2021 19:18:39 +0200 Subject: [PATCH] DB facade alias support (#126) * Convert DB facade stub method to static --- stubs/DBFacade.stubphp | 4 ++-- tests/acceptance/DBFacadeAlias.feature | 31 ++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 tests/acceptance/DBFacadeAlias.feature diff --git a/stubs/DBFacade.stubphp b/stubs/DBFacade.stubphp index 6cdaedd7..32091a9b 100644 --- a/stubs/DBFacade.stubphp +++ b/stubs/DBFacade.stubphp @@ -12,5 +12,5 @@ class DB extends Facade * * @psalm-taint-sink sql $value */ - public function raw($value) {} -} \ No newline at end of file + public static function raw($value) {} +} diff --git a/tests/acceptance/DBFacadeAlias.feature b/tests/acceptance/DBFacadeAlias.feature new file mode 100644 index 00000000..47a159ef --- /dev/null +++ b/tests/acceptance/DBFacadeAlias.feature @@ -0,0 +1,31 @@ +Feature: DB facade alias + Want to check that the alias of the DB facade works properly + + Background: + Given I have the following config + """ + + + + + + + + + + + """ + + Scenario: call the DB facade alias + Given I have the following code + """ +