-
Notifications
You must be signed in to change notification settings - Fork 71
48 lines (43 loc) · 1.35 KB
/
test-build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Test Build
on:
push:
branches:
- main
jobs:
test-build:
name: "Test Build"
runs-on: ubuntu-latest
container:
image: python:3.8
steps:
- name: Check out repository code
uses: actions/checkout@v2
with:
submodules: recursive
- name: Install build dependencies
run: pip install build virtualenv
- name: Test build
run: python -m build
- name: Verify files in build
run: |
for f in generativeimage2text/* generativeimage2text/**/*;
do
tar -tzvf dist/generativeimage2text*.tar.gz | grep -q $f
if [ $? -eq 1 ]; then
exit 1
fi
done
test-installation:
name: "Test Installation"
runs-on: ubuntu-latest
container:
image: python:3.8
steps:
- name: Check out repository code
uses: actions/checkout@v2
with:
submodules: recursive
- name: Install locally
run: pip install -e .
- name: Test execution
run: python -c "from generativeimage2text.inference import test_git_inference_single_image"