Speed up two slowest specs (~2.2s combined) #263
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: test_11g | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| types: [opened, synchronize, reopened, ready_for_review] | |
| jobs: | |
| build: | |
| if: github.event_name != 'pull_request' || !github.event.pull_request.draft | |
| runs-on: ubuntu-latest | |
| continue-on-error: false | |
| strategy: | |
| matrix: | |
| ruby: [ | |
| '4.0', | |
| '3.4', | |
| '3.3', | |
| 'jruby-10.1.0.0', | |
| ] | |
| env: | |
| ORACLE_HOME: /opt/oracle/instantclient_21_21 | |
| LD_LIBRARY_PATH: /opt/oracle/instantclient_21_21 | |
| NLS_LANG: AMERICAN_AMERICA.AL32UTF8 | |
| TNS_ADMIN: ./ci/network/admin | |
| DATABASE_NAME: XE | |
| TZ: Europe/Riga | |
| DATABASE_SYS_PASSWORD: Oracle18 | |
| services: | |
| oracle: | |
| image: gvenzl/oracle-xe:11 | |
| ports: | |
| - 1521:1521 | |
| env: | |
| TZ: Europe/Riga | |
| ORACLE_PASSWORD: Oracle18 | |
| options: >- | |
| --health-cmd healthcheck.sh | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Java | |
| if: startsWith(matrix.ruby, 'jruby') | |
| uses: actions/setup-java@v5 | |
| with: | |
| distribution: oracle | |
| java-version: '21' | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: ${{ matrix.ruby }} | |
| - name: Create symbolic link for libaio library compatibility | |
| run: | | |
| sudo ln -s /usr/lib/x86_64-linux-gnu/libaio.so.1t64 /usr/lib/x86_64-linux-gnu/libaio.so.1 | |
| - name: Download Oracle instant client | |
| run: | | |
| wget -q https://download.oracle.com/otn_software/linux/instantclient/2121000/instantclient-basic-linux.x64-21.21.0.0.0dbru.zip | |
| wget -q https://download.oracle.com/otn_software/linux/instantclient/2121000/instantclient-sqlplus-linux.x64-21.21.0.0.0dbru.zip | |
| wget -q https://download.oracle.com/otn_software/linux/instantclient/2121000/instantclient-sdk-linux.x64-21.21.0.0.0dbru.zip | |
| - name: Install Oracle instant client | |
| run: | | |
| sudo mkdir -p /opt/oracle/ | |
| sudo unzip -q instantclient-basic-linux.x64-21.21.0.0.0dbru.zip -d /opt/oracle | |
| sudo unzip -qo instantclient-sqlplus-linux.x64-21.21.0.0.0dbru.zip -d /opt/oracle | |
| sudo unzip -qo instantclient-sdk-linux.x64-21.21.0.0.0dbru.zip -d /opt/oracle | |
| echo "/opt/oracle/instantclient_21_21" >> $GITHUB_PATH | |
| - name: Install JDBC Driver | |
| if: startsWith(matrix.ruby, 'jruby') | |
| run: | | |
| wget -q https://download.oracle.com/otn-pub/otn_software/jdbc/23261/ojdbc17.jar -O ./lib/ojdbc17.jar | |
| - name: Configure ORA_TZFILE to match Oracle 11g server | |
| run: | | |
| # Oracle 11g XE uses timezone file v14; the 21.x Instant Client | |
| # embeds a newer file. The mismatch causes ORA-01805 when fetching | |
| # DATE/TIMESTAMP values. Copy the v14 files from the 11g container | |
| # and point the Instant Client at them via ORA_TZFILE. | |
| ORACLE_CONTAINER="${{ job.services.oracle.id }}" | |
| sudo mkdir -p "$ORACLE_HOME/oracore/zoneinfo" | |
| docker cp "$ORACLE_CONTAINER":/u01/app/oracle/product/11.2.0/xe/oracore/zoneinfo/timezlrg_14.dat /tmp/timezlrg_14.dat | |
| docker cp "$ORACLE_CONTAINER":/u01/app/oracle/product/11.2.0/xe/oracore/zoneinfo/timezone_14.dat /tmp/timezone_14.dat | |
| sudo mv /tmp/timezlrg_14.dat "$ORACLE_HOME/oracore/zoneinfo/" | |
| sudo mv /tmp/timezone_14.dat "$ORACLE_HOME/oracore/zoneinfo/" | |
| echo "ORA_TZFILE=timezlrg_14.dat" >> $GITHUB_ENV | |
| - name: Create database user | |
| run: | | |
| ./ci/setup_accounts.sh | |
| - name: Bundle install | |
| run: | | |
| bundle install --jobs 4 --retry 3 | |
| - name: Run RSpec | |
| run: | | |
| RUBYOPT=-w bundle exec rspec |