name: Renode Automated multi memory configurations

on:
  push:
    branches: [ 'master', 'main', 'release/**' ]
  pull_request:
    branches: [ '*' ]

jobs:
  renode_automated_fastmath:
    runs-on: ubuntu-20.04

    steps:
      - uses: actions/checkout@v2
        with:
          submodules: true

      - name: Select config
        run: |
          cp config/examples/nrf52840.config .config && make include/target.h

##### FAST MATH tests

# ECC256 TEST
      - name: Renode Tests ECC256
        run: ./tools/renode/docker-test.sh "SIGN=ECC256 SPMATH=0"


# ECC384 TEST
      - name: Renode Tests ECC384
        run: ./tools/renode/docker-test.sh "SIGN=ECC384 SPMATH=0"

# ECC521 TEST
      - name: Renode Tests ECC521
        run: ./tools/renode/docker-test.sh "SIGN=ECC521 SPMATH=0"


# RSA2048 TEST
      - name: Renode Tests RSA2048
        run: ./tools/renode/docker-test.sh "SIGN=RSA2048 SPMATH=0"



# RSA4096 TEST: RSA with TFM requires a very large stack (>64KB) total
# This test has been disabled.
# RSA3072 TEST
#      - name: Renode Tests RSA3072
#        run: ./tools/renode/docker-test.sh "SIGN=RSA3072 SPMATH=0"


# RSA4096 TEST: RSA with TFM requires the possibility to allocate
# large amount of stack space (about 70KB) which are not available
# on the renode target. This test has been disabled.
