Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSybren A. Stüvel <sybren@blender.org>2021-10-25 15:21:35 +0300
committerSybren A. Stüvel <sybren@blender.org>2021-10-25 15:21:43 +0300
commitcdcca917cfa4df1bd8c3a31831bb460cc3e0f604 (patch)
treeaea90f1bdc413be25484938abd78c2edd1e498fc /source/blender/blenkernel/intern/asset_library_test.cc
parent4100a79219e7f7c474046806db3e156be34a1011 (diff)
Tests: assets, add BKE callback init/finalize to test setup/teardown
Add calls to `BKE_callback_global_init()` and `BKE_callback_global_finalize()` to ensure unit tests mimick Blender (and don't trip the assertions added in rBbeea601e7253). No functional changes to Blender.
Diffstat (limited to 'source/blender/blenkernel/intern/asset_library_test.cc')
-rw-r--r--source/blender/blenkernel/intern/asset_library_test.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/asset_library_test.cc b/source/blender/blenkernel/intern/asset_library_test.cc
index c6c949a7ec4..702008fed96 100644
--- a/source/blender/blenkernel/intern/asset_library_test.cc
+++ b/source/blender/blenkernel/intern/asset_library_test.cc
@@ -20,6 +20,7 @@
#include "BKE_appdir.h"
#include "BKE_asset_catalog.hh"
#include "BKE_asset_library.hh"
+#include "BKE_callbacks.h"
#include "asset_library_service.hh"
@@ -34,10 +35,12 @@ class AssetLibraryTest : public testing::Test {
static void SetUpTestSuite()
{
CLG_init();
+ BKE_callback_global_init();
}
static void TearDownTestSuite()
{
CLG_exit();
+ BKE_callback_global_finalize();
}
void TearDown() override