Skip to content

Commit

Permalink
Use latest versions of python libraries for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
sbidoul committed Jul 2, 2024
1 parent f641d25 commit 7bcd072
Show file tree
Hide file tree
Showing 8 changed files with 75 additions and 15 deletions.
22 changes: 7 additions & 15 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -105,23 +105,15 @@ ENV PATH=/opt/odoo-venv/bin:$PATH

ARG odoo_version

# Install Odoo requirements (use ADD for correct layer caching).
# We use requirements from OCB for easier maintenance of older versions.
# We use no-binary for psycopg2 because its binary wheels are sometimes broken
# and not very portable.
ADD https://raw.githubusercontent.com/OCA/OCB/$odoo_version/requirements.txt /tmp/ocb-requirements.txt
RUN pip install --no-cache-dir --no-binary psycopg2 -r /tmp/ocb-requirements.txt

# Install other test requirements.
# - coverage
# - websocket-client is required for Odoo browser tests
RUN pip install --no-cache-dir \
coverage \
websocket-client

# Install Odoo (use ADD for correct layer caching)
# Use ADD to rebuild from here when Odoo HEAD changes
ARG odoo_org_repo=odoo/odoo
ADD https://api.github.com/repos/$odoo_org_repo/git/refs/heads/$odoo_version /tmp/odoo-version.json

# Install Odoo requirements.
COPY requirements-${odoo_version}.txt /tmp/requirements.txt
RUN pip install --no-cache-dir --no-binary psycopg2 -r /tmp/requirements.txt

# Install Odoo (use ADD for correct layer caching)
RUN mkdir /tmp/getodoo \
&& (curl -sSL https://github.com/$odoo_org_repo/tarball/$odoo_version | tar -C /tmp/getodoo -xz) \
&& mv /tmp/getodoo/* /opt/odoo \
Expand Down
5 changes: 5 additions & 0 deletions requirements-11.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
https://raw.githubusercontent.com/OCA/OCB/11.0/requirements.txt

# other test requirements
coverage
websocket-client
5 changes: 5 additions & 0 deletions requirements-12.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
https://raw.githubusercontent.com/OCA/OCB/12.0/requirements.txt

# other test requirements
coverage
websocket-client
5 changes: 5 additions & 0 deletions requirements-13.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
https://raw.githubusercontent.com/OCA/OCB/13.0/requirements.txt

# other test requirements
coverage
websocket-client
5 changes: 5 additions & 0 deletions requirements-14.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
https://raw.githubusercontent.com/OCA/OCB/14.0/requirements.txt

# other test requirements
coverage
websocket-client
16 changes: 16 additions & 0 deletions requirements-15.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Add requirements and bounds that are missing from setup.py.
freezegun
lxml-html-clean
num2words
pdfminer
pypdf2<3
rl-renderPM # reportlab accelerator
xlrd<2 # xlrd 2 dropped xlsx reading capability

# We use no-binary for psycopg2 because its binary wheels are sometimes broken
# and not very portable.
--no-binary psycopg2

# other test requirements
coverage
websocket-client
16 changes: 16 additions & 0 deletions requirements-16.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Add requirements and bounds that are missing from setup.py.
freezegun
lxml-html-clean
num2words
pdfminer
pypdf2<3
rl-renderPM # reportlab accelerator
xlrd<2 # xlrd 2 dropped xlsx reading capability

# We use no-binary for psycopg2 because its binary wheels are sometimes broken
# and not very portable.
--no-binary psycopg2

# other test requirements
coverage
websocket-client
16 changes: 16 additions & 0 deletions requirements-17.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Add requirements and bounds that are missing from setup.py.
freezegun
lxml-html-clean
num2words
pdfminer
pypdf2<3
rl-renderPM # reportlab accelerator
xlrd<2 # xlrd 2 dropped xlsx reading capability

# We use no-binary for psycopg2 because its binary wheels are sometimes broken
# and not very portable.
--no-binary psycopg2

# other test requirements
coverage
websocket-client

0 comments on commit 7bcd072

Please sign in to comment.