Skip to content

Commit

Permalink
Merge pull request #58 from ba-st/pharo11
Browse files Browse the repository at this point in the history
Add Pharo 11
  • Loading branch information
gcotelli authored May 24, 2023
2 parents 7a07ccc + 54c688d commit 5b6d036
Show file tree
Hide file tree
Showing 11 changed files with 42 additions and 47 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Integration Tests

on: [push,pull_request,workflow_dispatch]

jobs:
integration-tests:
runs-on: ubuntu-latest
name: Integration Tests
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Run tests using Docker
run: ./compose-test.sh
4 changes: 2 additions & 2 deletions .github/workflows/loading-groups.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
strategy:
fail-fast: false
matrix:
smalltalk: [ Pharo64-10, Pharo64-9.0, Pharo64-8.0 ]
smalltalk: [ Pharo64-11, Pharo64-10, Pharo64-9.0, Pharo64-8.0 ]
load-spec: [ core, api-client, service-discovery, deployment, examples, dependent-sunit-extensions]
name: ${{ matrix.smalltalk }} + ${{ matrix.load-spec }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: hpi-swa/setup-smalltalkCI@v1
with:
smalltalk-image: ${{ matrix.smalltalk }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/markdown-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: markdownlint
uses: reviewdog/action-markdownlint@v0.1
uses: reviewdog/action-markdownlint@v0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
fail_on_error: true
Expand Down
10 changes: 4 additions & 6 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
smalltalk: [ Pharo64-10, Pharo64-8.0, Pharo64-9.0 ]
smalltalk: [ Pharo64-11, Pharo64-10, Pharo64-8.0, Pharo64-9.0 ]
name: ${{ matrix.smalltalk }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Start httpbin
run: docker run -d -p 127.0.0.1:80:80 fortizpenaloza/httpbin
- name: Start memcached
Expand All @@ -23,10 +23,8 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
timeout-minutes: 15
- name: Run tests using Docker
run: ./compose-test.sh
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v3
with:
name: ${{matrix.os}}-${{matrix.smalltalk}}
name: Unit-Tests-${{matrix.smalltalk}}
token: ${{ secrets.CODECOV_TOKEN }}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Building blocks for creating HTTP requests and API clients
[![Pharo 8.0](https://img.shields.io/badge/Pharo-8.0-informational)](https://pharo.org)
[![Pharo 9.0](https://img.shields.io/badge/Pharo-9.0-informational)](https://pharo.org)
[![Pharo 10](https://img.shields.io/badge/Pharo-10-informational)](https://pharo.org)
[![Pharo 11](https://img.shields.io/badge/Pharo-11-informational)](https://pharo.org)

Quick links

Expand Down
20 changes: 8 additions & 12 deletions api-tests/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,26 +1,22 @@
# Stage 1: Load the project
FROM basmalltalk/pharo:8.0-image AS loader
ARG BRANCH_NAME=release-candidate
ENV BRANCH_NAME=$BRANCH_NAME
COPY load-project.st ./
RUN pharo Pharo.image load-project.st --save --quit
FROM ghcr.io/ba-st/pharo-loader:v11.0.0 AS loader

COPY --chown=pharo:users ./source /opt/pharo/source
COPY --chown=pharo:users ./.git /opt/pharo/.git
RUN pharo metacello install gitlocal://. BaselineOfSuperluminal --groups=Examples

# Stage 2: Copy the resulting Pharo.image with our project loaded
# into a new docker image with just the vm
FROM basmalltalk/pharo:8.0
FROM ghcr.io/ba-st/launchpad:v4

USER root

WORKDIR /opt/app
COPY start.sh ./
COPY --from=loader /opt/pharo/Pharo.image ./
COPY --from=loader /opt/pharo/Pharo.changes ./
COPY --from=loader /opt/pharo/Pharo*.sources ./

RUN mkdir logs \
&& chmod a+x start.sh \
&& chown --recursive pharo:users /opt/app
&& chown --recursive pharo:users /opt/pharo

USER pharo

CMD ["./start.sh"]
CMD ["launchpad-start", "superluminal-service-discovery", "--retry-delay-in-ms=10000"]
5 changes: 2 additions & 3 deletions api-tests/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,8 @@ services:
CONSUL_BIND_INTERFACE: eth0
api-client:
build:
context: ./
args:
- BRANCH_NAME
context: ../
dockerfile: api-tests/Dockerfile
environment:
MESSAGE: 'Hello'
CONSUL_AGENT_LOCATION: http://consul-agent:8500
Expand Down
11 changes: 0 additions & 11 deletions api-tests/load-project.st

This file was deleted.

6 changes: 0 additions & 6 deletions api-tests/start.sh

This file was deleted.

6 changes: 5 additions & 1 deletion compose-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,8 @@ else
echo "BRANCH_NAME=${GITHUB_HEAD_REF##*/}" > api-tests/.env
fi
set +e # disable exit on error to be able to catch the exit code from compose
docker-compose -f api-tests/docker-compose.yml up --exit-code-from api-client
docker compose \
--file api-tests/docker-compose.yml \
up \
--build api-client \
--exit-code-from api-client
10 changes: 5 additions & 5 deletions source/BaselineOfSuperluminal/BaselineOfSuperluminal.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -45,23 +45,23 @@ BaselineOfSuperluminal >> setUpDependencies: spec [
project: 'Launchpad-Deployment' copyFrom: 'Launchpad' with: [ spec loads: 'Deployment' ].

spec
baseline: 'NeoJSON' with: [ spec repository: 'github://svenvc/NeoJSON:master/repository' ];
baseline: 'NeoJSON' with: [ spec repository: 'github://svenvc/NeoJSON:master' ];
project: 'NeoJSON-Core' copyFrom: 'NeoJSON' with: [ spec loads: 'core' ].

spec
baseline: 'ObjectPool' with: [ spec repository: 'github://pharo-ide/ObjectPool:v1.0.2' ];
baseline: 'ObjectPool' with: [ spec repository: 'github://pharo-ide/ObjectPool:v1.0.3' ];
project: 'ObjectPool-Core' copyFrom: 'ObjectPool' with: [ spec loads: 'Core' ].

spec
baseline: 'Teapot' with: [ spec repository: 'github://zeroflag/Teapot:v2.6.0/source' ];
baseline: 'Teapot' with: [ spec repository: 'github://zeroflag/Teapot:v2.7.0/source' ];
project: 'Teapot-Deployment' copyFrom: 'Teapot' with: [ spec loads: 'Deployment' ].

spec
baseline: 'Teachable' with: [ spec repository: 'github://astares/Pharo-Teachable:master/src' ];
baseline: 'Teachable' with: [ spec repository: 'github://astares/Pharo-Teachable:master' ];
project: 'Teachable-Core' copyFrom: 'Teachable' with: [ spec loads: 'Core' ].

spec
baseline: 'Memcached' with: [ spec repository: 'github://svenvc/memcached:v1' ];
baseline: 'Memcached' with: [ spec repository: 'github://svenvc/memcached:master' ];
project: 'Memcached-Core' copyFrom: 'Memcached' with: [ spec loads: 'Deployment' ]
]

Expand Down

0 comments on commit 5b6d036

Please sign in to comment.