Skip to content
Snippets Groups Projects
Select Git revision
  • 15ecb0182499b6960482f29ad3e235a04f6d2eb8
  • master default protected
  • devel
  • feature/add-escaping-to-templates
  • feature/add-priority-sorting
  • 3.3.0
  • 3.2.1
  • 3.2.0
  • 3.1.0
  • 3.0.0
  • 2.4.12
  • 2.4.11
  • 2.4.10
  • 2.4.9
  • 2.4.8
  • 2.4.7
  • 2.4.6
  • 2.4.5
  • 2.4.4
  • 2.4.2
  • 2.4.1
  • 2.4.0
  • 2.3.2
  • 2.3.1
  • 2.3
25 results

JsonNormalizedRenderer.php

Blame
  • static-analysis.yml 1.23 KiB
    .static-analysis: &static-tmpl
      image: gitlab.wpdesk.dev:5050/wpdesk/docker-tests/php-box:8.2
      needs:
        - prepare prefixed vendor
      stage: tests
      extends: .skip-mr
    
    # Run phpstan in strict mode (failing pipeline) only if we have baseline, otherwise allow to fail with a warning, suggesting to create one. This behavior will change at the end of the year, when any PHPStan failure will be considered fatal
    phpstan:
      <<: *static-tmpl
      script:
        - |
          if [ -f "vendor/bin/phpstan" ]; then
            vendor/bin/phpstan analyse --memory-limit=2G
          elif [ -f "vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan" ]; then
            # PHPStan installed by director
            vendor/wpdesk/wp-wpdesk-composer/director/vendor/bin/phpstan analyse --memory-limit=2G
          else
            echo "PHPStan not found! Install it with 'composer require --dev wpdesk/phpstan-rules'."
            # We will be able to use custom exit after removing rules.allow_failure part
            # exit 125
          fi
      allow_failure: true
      rules:
        - exists:
          - .phpstan-baseline.php
          - .phpstan-baseline.neon
          allow_failure: false
    
    phpcs:
      <<: *static-tmpl
      script:
        - vendor/bin/phpcs
      allow_failure: true
      rules:
        - exists:
          - phpcs.xml.dist