
name: trading_ig integration test

on:
  schedule:
    - cron:  '0 1 * * *'
  #workflow_dispatch:
    
jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
    - name: Set up Python 3.8
      uses: actions/setup-python@v2
      with:
        python-version: 3.8
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install flake8 pytest
        pip install .
        pip install -r requirements.txt
    - name: Integration test with pytest
      env:
        IG_SERVICE_USERNAME:  ${{ secrets.IG_SERVICE_USERNAME }}
        IG_SERVICE_PASSWORD:  ${{ secrets.IG_SERVICE_PASSWORD }}
        IG_SERVICE_API_KEY:  ${{ secrets.IG_SERVICE_API_KEY }}
        IG_SERVICE_ACC_TYPE:  ${{ secrets.IG_SERVICE_ACC_TYPE }}
        IG_SERVICE_ACC_NUMBER:  ${{ secrets.IG_SERVICE_ACC_NUMBER_1 }}
      run: |
        pytest --ignore=tests/test_session.py --ignore=tests/test_utils.py


name: trading_ig integration test

on:
  schedule:
    - cron:  '0 1 * * *'
  workflow_dispatch:
    
jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
    - name: Set up Python 3.8
      uses: actions/setup-python@v2
      with:
        python-version: 3.8
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install flake8 pytest
        pip install .
        pip install -r requirements.txt
    - name: Integration test with pytest
      env:
        IG_SERVICE_USERNAME:  ${{ secrets.IG_SERVICE_USERNAME }}
        IG_SERVICE_PASSWORD:  ${{ secrets.IG_SERVICE_PASSWORD }}
        IG_SERVICE_API_KEY:  ${{ secrets.IG_SERVICE_API_KEY }}
        IG_SERVICE_ACC_TYPE:  ${{ secrets.IG_SERVICE_ACC_TYPE }}
        IG_SERVICE_ACC_NUMBER:  ${{ secrets.IG_SERVICE_ACC_NUMBER_1 }}
      run: |
        pytest --ignore=tests/test_session.py --ignore=tests/test_utils.py

Allow manual trigger as well as scheduled
Allow manual trigger as well as scheduled