Skip to content

Commit 268d2dd

Browse files
committed
fix: Odoo 19, stricter boolean values in configuration
1 parent 72c6e48 commit 268d2dd

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

bin/docker-entrypoint.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,10 @@ fi
3434
# that's why we propose DEMO which exports WITHOUT_DEMO used in
3535
# odoo.cfg.tmpl
3636
if [ -z "$DEMO" ]; then
37-
DEMO=False
37+
if [ "$BASE_CMD" = "runtests" ] || [ "$BASE_CMD" = "testdb-gen" ] || [ "$BASE_CMD" = "testdb-update" ]; then
38+
DEMO=True
39+
else
40+
DEMO=False
3841
fi
3942
case "$(echo "${DEMO}" | tr '[:upper:]' '[:lower:]')" in
4043
"false")
@@ -43,7 +46,7 @@ case "$(echo "${DEMO}" | tr '[:upper:]' '[:lower:]')" in
4346
;;
4447
"true")
4548
echo "Running with demo data"
46-
export WITHOUT_DEMO=
49+
export WITHOUT_DEMO=False
4750
;;
4851
*)
4952
echo "Value '${DEMO}' for DEMO is not a valid value in 'False', 'True'"

bin/runtests

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,14 +66,14 @@ else
6666
fi
6767
echo "🔨🔨 Install official/OCA modules 🔨🔨"
6868
echo "${DEPS_ADDONS}"
69-
odoo --stop-after-init --workers=0 --database $DB_NAME_TEST --log-level=warn --without-demo="" --db-filter=$DB_NAME_TEST -i ${DEPS_ADDONS}
69+
odoo --stop-after-init --workers=0 --database $DB_NAME_TEST --log-level=warn --db-filter=$DB_NAME_TEST -i ${DEPS_ADDONS}
7070
if [ "$CREATE_DB_CACHE" == "true" -a ! -z "$CACHED_DUMP" ]; then
7171
echo "Generate dump $CACHED_DUMP into cache 🐘⮕ 📦"
7272
mkdir -p "$CACHE_DIR"
7373
pg_dump -Fp -d $DB_NAME_TEST -O -f "$CACHED_DUMP"
7474
fi
7575
fi
7676
echo "🔧🔧 Install odoo/addons modules 🔧🔧"
77-
odoo --stop-after-init --workers=0 --database $DB_NAME_TEST --test-enable --log-level=test --log-handler=":INFO" --without-demo="" --db-filter=$DB_NAME_TEST -i ${LOCAL_ADDONS}
77+
odoo --stop-after-init --workers=0 --database $DB_NAME_TEST --test-enable --log-level=test --log-handler=":INFO" --db-filter=$DB_NAME_TEST -i ${LOCAL_ADDONS}
7878

7979
dropdb ${DB_NAME_TEST}

bin/testdb-gen

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@ fi
1616

1717
echo "creating database ${DB_NAME}"
1818
createdb -h ${DB_HOST} -O ${DB_USER} ${DB_NAME}
19-
odoo --stop-after-init --workers=0 --log-level=warn --without-demo="" "$@"
19+
odoo --stop-after-init --workers=0 --log-level=warn "$@"
2020
echo "done"

bin/testdb-update

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@ if ! psql -lqtA -h ${DB_HOST} | grep -q "^$DB_NAME|"; then
1515
fi
1616

1717
echo "updating database ${DB_NAME}"
18-
odoo --stop-after-init --workers=0 --log-level=warn --without-demo="" "$@"
18+
odoo --stop-after-init --workers=0 --log-level=warn "$@"
1919
echo "done"

0 commit comments

Comments
 (0)