<commit_before>name: build

on:
  push:
    branches: [ master, '[0-9]+.[0-9]' ]
  pull_request:
    branches: [ master, '[0-9]+.[0-9]' ]

jobs:
  build:
    if: "!contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[skip travis]')"
    name: "PHP ${{ matrix.php-versions }} Test ${{ matrix.static-analysis != 'no' && matrix.static-analysis || '' }} (deps: ${{ matrix.dependencies }})"

    continue-on-error: ${{ matrix.experimental }}

    strategy:
      fail-fast: false
      matrix:
        php-versions: ['8.0', '8.1']
        dependencies: ['highest']
        composer-arguments: [''] # to run --ignore-platform-reqs in experimental builds
        static-analysis: ['no']
        experimental: [false]
        include:
          - php-versions: '8.0'
            static-analysis: 'psalm'
            experimental: true
            dependencies: 'highest'

          # Experimental build for PHP nightly
          #- php-versions: 'nightly'
          #  composer-arguments: '--ignore-platform-reqs'
          #  static-analysis: 'no'
          #  experimental: true
          #  dependencies: 'highest'

          # Build for minimum dependencies.
          - php-versions: '8.0'
            static-analysis: 'no'
            experimental: false
            dependencies: 'lowest'

    runs-on: ubuntu-latest
    services:
      mariadb:
        image: mariadb:10.2
        env:
          MYSQL_USER: neos
          MYSQL_PASSWORD: <PASSWORD>
          MYSQL_DATABASE: flow_functional_testing
          MYSQL_ROOT_PASSWORD: <PASSWORD>
        ports:
          - "3306:3306"
        options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
      postgres:
        image: postgres:9.5-alpine
        env:
          POSTGRES_USER: neos
          POSTGRES_PASSWORD: neos
          POSTGRES_DB: flow_functional_testing
        ports:
          - "5432:5432"
        options:  --health-cmd=pg_isready --health-interval=10s --health-timeout=5s --health-retries=3
      redis:
        image: redis:alpine
        ports:
          - "6379:6379"
        options: --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5
      memcached:
        image: memcached:alpine
        ports:
          - "11211:11211"
        # options: --health-cmd "timeout 5 bash -c 'cat < /dev/null > /dev/udp/127.0.0.1/11211'" --health-interval 10s --health-timeout 5s --health-retries 5

    env:
      FLOW_CONTEXT: Testing
      FLOW_DIST_FOLDER: flow-development-distribution
      FLOW_FOLDER: flow-development-collection

    defaults:
      run:
        working-directory: ${{ env.FLOW_DIST_FOLDER }}<commit_msg>TASK: Run tests against current PostgreSQL version<commit_after>name: build

on:
  push:
    branches: [ master, '[0-9]+.[0-9]' ]
  pull_request:
    branches: [ master, '[0-9]+.[0-9]' ]

jobs:
  build:
    if: "!contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[skip travis]')"
    name: "PHP ${{ matrix.php-versions }} Test ${{ matrix.static-analysis != 'no' && matrix.static-analysis || '' }} (deps: ${{ matrix.dependencies }})"

    continue-on-error: ${{ matrix.experimental }}

    strategy:
      fail-fast: false
      matrix:
        php-versions: ['8.0', '8.1']
        dependencies: ['highest']
        composer-arguments: [''] # to run --ignore-platform-reqs in experimental builds
        static-analysis: ['no']
        experimental: [false]
        include:
          - php-versions: '8.0'
            static-analysis: 'psalm'
            experimental: true
            dependencies: 'highest'

          # Experimental build for PHP nightly
          #- php-versions: 'nightly'
          #  composer-arguments: '--ignore-platform-reqs'
          #  static-analysis: 'no'
          #  experimental: true
          #  dependencies: 'highest'

          # Build for minimum dependencies.
          - php-versions: '8.0'
            static-analysis: 'no'
            experimental: false
            dependencies: 'lowest'

    runs-on: ubuntu-latest
    services:
      mariadb:
        image: mariadb:10.2
        env:
          MYSQL_USER: neos
          MYSQL_PASSWORD: <PASSWORD>
          MYSQL_DATABASE: flow_functional_testing
          MYSQL_ROOT_PASSWORD: <PASSWORD>
        ports:
          - "3306:3306"
        options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
      postgres:
        # see https://www.postgresql.org/support/versioning/
        # this should be a current release
        image: postgres:14-alpine
        env:
          POSTGRES_USER: neos
          POSTGRES_PASSWORD: <PASSWORD>
          POSTGRES_DB: flow_functional_testing
        ports:
          - "5432:5432"
        options:  --health-cmd=pg_isready --health-interval=10s --health-timeout=5s --health-retries=3
      redis:
        image: redis:alpine
        ports:
          - "6379:6379"
        options: --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5
      memcached:
        image: memcached:alpine
        ports:
          - "11211:11211"
        # options: --health-cmd "timeout 5 bash -c 'cat < /dev/null > /dev/udp/127.0.0.1/11211'" --health-interval 10s --health-timeout 5s --health-retries 5

    env:
      FLOW_CONTEXT: Testing
      FLOW_DIST_FOLDER: flow-development-distribution
      FLOW_FOLDER: flow-development-collection

    defaults:
      run:
        working-directory: ${{ env.FLOW_DIST_FOLDER }}
{'fraction_non_alphanumeric': 0.13111825652018577, 'fraction_numerical': 0.02965344765987853, 'mean_word_length': 2.0713110257816787, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 10, 'https://': 1, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5294764', 'n_tokens_mistral': 1888, 'n_tokens_neox': 1744, 'n_words': 360}