Project

General

Profile

Actions

Task #90984

closed

Add `phpstan analyse` to Build/Scripts/runTests.sh

Added by Jonas Eberle over 4 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Tests
Target version:
-
Start date:
2020-04-09
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
10
PHP Version:
Tags:
phpstan
Complexity:
Sprint Focus:

Description

command from Build/bamboo/src/main/java/core/AbstractCoreSpec.java

                            "    docker run \\\n" +
                            "        -u ${HOST_UID} \\\n" +
                            "        -v /bamboo-data/${BAMBOO_COMPOSE_PROJECT_NAME}/passwd:/etc/passwd \\\n" +
                            "        -v ${BAMBOO_COMPOSE_PROJECT_NAME}_bamboo-data:/srv/bamboo/xml-data/build-dir/ \\\n" +
                            "        --name ${BAMBOO_COMPOSE_PROJECT_NAME}sib_adhoc \\\n" +
                            "        --rm \\\n" +
                            "        typo3gmbh/" + requirementIdentifier.toLowerCase() + ":latest \\\n" +
                            "        bin/bash -c \"cd ${PWD}; ./bin/phpstan analyse --no-progress --no-interaction $*\"\n" +

It is using the same image as the other tests.

There should be no reason not to have it in our official local test runner script.


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Task #93367: runTests.sh: Add phpstan and docBlockCheckClosed2021-01-26

Actions
Actions #1

Updated by Benni Mack over 4 years ago

Please specify what you want to do, Jonas, and the reason behind it.

Actions #2

Updated by Jonas Eberle over 4 years ago

I am suggesting to add a `phpstan` command to our local test runner environment `runTests.sh`.

The reasoning is that `phpstan` is run in the bamboo tests and in my opinion it should be possible to run CI-checks locally, too.

In this case it is very easy to accomplish, too.

Actions #3

Updated by Benni Mack over 4 years ago

Yes, I see that this would be easy to accomplish, but this would mean that our test runs would be much slower, right?

Actions #4

Updated by Jonas Eberle over 4 years ago

Benni Mack wrote:

but this would mean that our test runs would be much slower, right?

It would be a separate subcommand (./Build/runTests.sh phpstan ...) and would not affect other tests run locally or even the bamboo tests.

Actions #5

Updated by Benni Mack over 4 years ago

  • Status changed from New to Accepted

Let's assume I would accept this issue...

Actions #6

Updated by Benni Mack over 3 years ago

  • Related to Task #93367: runTests.sh: Add phpstan and docBlockCheck added
Actions #7

Updated by Benni Mack over 3 years ago

  • Status changed from Accepted to Closed
Actions

Also available in: Atom PDF