|
40 | 40 | needs: setup |
41 | 41 | steps: |
42 | 42 | - uses: actions/checkout@v3 |
43 | | - - uses: actions/cache@v3 |
| 43 | + - uses: actions/cache/restore@v3 |
44 | 44 | id: virtualenv-cache |
45 | 45 | with: |
46 | 46 | path: .venv |
|
70 | 70 | needs: [setup, lint] |
71 | 71 | steps: |
72 | 72 | - uses: actions/checkout@v3 |
73 | | - - uses: actions/cache@v3 |
| 73 | + - uses: actions/cache/restore@v3 |
74 | 74 | id: virtualenv-cache |
75 | 75 | with: |
76 | 76 | path: | |
|
94 | 94 | make test |
95 | 95 | make check-coverage |
96 | 96 |
|
| 97 | + test_ingest: |
| 98 | + strategy: |
| 99 | + matrix: |
| 100 | + python-version: ["3.8","3.9","3.10"] |
| 101 | + runs-on: ubuntu-latest |
| 102 | + env: |
| 103 | + NLTK_DATA: ${{ github.workspace }}/nltk_data |
| 104 | + needs: lint |
| 105 | + steps: |
| 106 | + - name: Checkout unstructured repo for integration testing |
| 107 | + uses: actions/checkout@v3 |
| 108 | + with: |
| 109 | + repository: 'Unstructured-IO/unstructured' |
| 110 | + - name: Checkout this repo |
| 111 | + uses: actions/checkout@v3 |
| 112 | + with: |
| 113 | + path: inference |
| 114 | + - name: Set up Python ${{ matrix.python-version }} |
| 115 | + uses: actions/setup-python@v4 |
| 116 | + with: |
| 117 | + python-version: ${{ matrix.python-version }} |
| 118 | + - name: Test |
| 119 | + env: |
| 120 | + GH_READ_ONLY_ACCESS_TOKEN: ${{ secrets.GH_READ_ONLY_ACCESS_TOKEN }} |
| 121 | + SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }} |
| 122 | + DISCORD_TOKEN: ${{ secrets.DISCORD_TOKEN }} |
| 123 | + run: | |
| 124 | + python${{ matrix.python-version }} -m venv .venv |
| 125 | + source .venv/bin/activate |
| 126 | + [ ! -d "$NLTK_DATA" ] && mkdir "$NLTK_DATA" |
| 127 | + make install-ci |
| 128 | + pip install -e inference/ |
| 129 | + sudo apt-get update |
| 130 | + sudo apt-get install -y libmagic-dev poppler-utils libreoffice pandoc |
| 131 | + sudo add-apt-repository -y ppa:alex-p/tesseract-ocr5 |
| 132 | + sudo apt-get install -y tesseract-ocr |
| 133 | + tesseract --version |
| 134 | + make install-ingest-s3 |
| 135 | + make install-ingest-azure |
| 136 | + make install-ingest-discord |
| 137 | + make install-ingest-github |
| 138 | + make install-ingest-gitlab |
| 139 | + make install-ingest-slack |
| 140 | + make install-ingest-wikipedia |
| 141 | + ./test_unstructured_ingest/test-ingest.sh |
| 142 | +
|
97 | 143 | changelog: |
98 | 144 | runs-on: ubuntu-latest |
99 | 145 | steps: |
|
0 commit comments