From f8dd09200f057b4d15cc5482569e33781d035070 Mon Sep 17 00:00:00 2001 From: Myk Taylor Date: Thu, 3 Aug 2023 23:54:14 -0700 Subject: [PATCH] enable remaining core and structures tests --- test/gui.lua | 4 +++- test/structures/find.lua | 1 + test/structures/misc.lua | 2 ++ test/structures/other_vectors.lua | 2 ++ test/structures/primitive_refs.lua | 2 ++ test/structures/ref_target.lua | 2 ++ test/structures/types_meta.lua | 2 ++ test/structures/unions.lua | 2 ++ 8 files changed, 16 insertions(+), 1 deletion(-) diff --git a/test/gui.lua b/test/gui.lua index 1550fc1de..ac350ea1b 100644 --- a/test/gui.lua +++ b/test/gui.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + function test.getCurViewscreen() local scr = dfhack.gui.getCurViewscreen() local scr2 = df.global.gview.view @@ -18,7 +20,7 @@ function test.getViewscreenByType() local bad_type = df.viewscreen_titlest if scr._type == bad_type then - bad_type = df.viewscreen_optionst + bad_type = df.viewscreen_dwarfmodest end local scr_bad = dfhack.gui.getViewscreenByType(bad_type) expect.eq(scr_bad, nil) diff --git a/test/structures/find.lua b/test/structures/find.lua index c01f071e1..471220479 100644 --- a/test/structures/find.lua +++ b/test/structures/find.lua @@ -1,4 +1,5 @@ config.mode = 'title' +config.targets = 'core' local function clean_vec(vec) while #vec > 0 do diff --git a/test/structures/misc.lua b/test/structures/misc.lua index 5c9f41561..277457dfe 100644 --- a/test/structures/misc.lua +++ b/test/structures/misc.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + function test.overlappingGlobals() local globals = {} for name, _ in pairs(df.global) do diff --git a/test/structures/other_vectors.lua b/test/structures/other_vectors.lua index bfc6086a4..453ab1dca 100644 --- a/test/structures/other_vectors.lua +++ b/test/structures/other_vectors.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + function test.index_name() for _, k in ipairs(df.units_other_id) do expect.eq(df.global.world.units.other[k]._kind, 'container') diff --git a/test/structures/primitive_refs.lua b/test/structures/primitive_refs.lua index 74abd02b9..77049b673 100644 --- a/test/structures/primitive_refs.lua +++ b/test/structures/primitive_refs.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + utils = require('utils') function with_temp_ref(...) diff --git a/test/structures/ref_target.lua b/test/structures/ref_target.lua index b9c568805..56bfdbfc7 100644 --- a/test/structures/ref_target.lua +++ b/test/structures/ref_target.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + function test.get() dfhack.with_temp_object(df.unit:new(), function(unit) expect.eq(unit:_field('hist_figure_id').ref_target, df.historical_figure) diff --git a/test/structures/types_meta.lua b/test/structures/types_meta.lua index 212e9c7ed..5809960bf 100644 --- a/test/structures/types_meta.lua +++ b/test/structures/types_meta.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + function test.struct() expect.eq(df.coord._kind, 'struct-type') expect.eq(tostring(df.coord), '') diff --git a/test/structures/unions.lua b/test/structures/unions.lua index 714786a96..9e4c767db 100644 --- a/test/structures/unions.lua +++ b/test/structures/unions.lua @@ -1,3 +1,5 @@ +config.targets = 'core' + local utils = require('utils') function test.unit_action_fields()