From a333daa15ae4aaad9ec76e7ea332f4f9bcd286f8 Mon Sep 17 00:00:00 2001 From: Oliver Hamlet Date: Tue, 25 Jun 2024 19:42:10 +0100 Subject: [PATCH] Fix override plugin FFI tests --- ffi/tests/ffi.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/ffi/tests/ffi.cpp b/ffi/tests/ffi.cpp index 042a997..a6650f7 100644 --- a/ffi/tests/ffi.cpp +++ b/ffi/tests/ffi.cpp @@ -138,7 +138,11 @@ void test_esp_plugin_is_light_plugin() { void test_esp_plugin_is_override_plugin() { printf("testing esp_plugin_is_override_plugin()...\n"); Plugin * plugin; - auto return_code = esp_plugin_new(&plugin, ESP_GAME_FALLOUT4, "../../testing-plugins/Skyrim/Data/Blank.esl"); + // The Skyrim SE light flag is the same value as the Starfield update flag. + auto return_code = esp_plugin_new(&plugin, ESP_GAME_STARFIELD, "../../testing-plugins/SkyrimSE/Data/Blank.esl"); + assert(return_code == ESP_OK); + + return_code = esp_plugin_parse(plugin, true); assert(return_code == ESP_OK); bool is_override_plugin; @@ -328,10 +332,10 @@ void test_esp_plugin_is_valid_as_light_plugin() { void test_esp_plugin_is_valid_as_override_plugin() { printf("testing esp_plugin_is_valid_as_override_plugin()...\n"); Plugin * plugin; - auto return_code = esp_plugin_new(&plugin, ESP_GAME_SKYRIMSE, "../../testing-plugins/SkyrimSE/Data/Blank.esm"); + auto return_code = esp_plugin_new(&plugin, ESP_GAME_STARFIELD, "../../testing-plugins/Starfield/Data/Blank.full.esm"); assert(return_code == ESP_OK); - return_code = esp_plugin_parse(plugin, true); + return_code = esp_plugin_parse(plugin, false); assert(return_code == ESP_OK); bool is_valid; @@ -353,6 +357,7 @@ int main() { test_esp_plugin_is_master(); test_esp_plugin_is_light_master(); test_esp_plugin_is_light_plugin(); + test_esp_plugin_is_override_plugin(); test_esp_plugin_is_valid(); test_esp_plugin_description(); test_esp_plugin_header_version();