From 6b0d13a5bffdf07ad6239afe9ee7bd88fd1303c5 Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Sat, 4 Jan 2025 12:14:55 +0530 Subject: [PATCH] test: avoid rebuilding assets --- .github/actions/setup/action.yml | 2 +- frappe/commands/test_commands.py | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index 1be6b0f4eb..29d48831f7 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -216,7 +216,7 @@ runs: start_time=$(date +%s) source ${GITHUB_WORKSPACE}/env/bin/activate - CI=Yes bench build & + CI=Yes bench build --force --production & build_pid=$! bench --site test_site reinstall --yes wait $build_pid diff --git a/frappe/commands/test_commands.py b/frappe/commands/test_commands.py index 21d9a08be5..e331543c59 100644 --- a/frappe/commands/test_commands.py +++ b/frappe/commands/test_commands.py @@ -897,12 +897,8 @@ class TestAddNewUser(BaseTestCommands): self.assertEqual({"Accounts User", "Sales User"}, roles) -class TestBenchBuild(BaseTestCommands): +class TestBenchBuild(IntegrationTestCase): def test_build_assets_size_check(self): - with cli(frappe.commands.utils.build, "--force --production --app frappe") as result: - self.assertEqual(result.exit_code, 0) - self.assertEqual(result.exception, None) - CURRENT_SIZE = 3.3 # MB JS_ASSET_THRESHOLD = 0.01