mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-10-13 16:34:14 +02:00
tst_wiringrules: skip the --run checks on a build without scripting
The project's CI builds QElectroTech without scripting, where --run is not an option and the process never exits, so the test waited out its timeout and failed (#1272's stack, CI run 37118548599). The --run checks now skip there, as the script tests are left out of such builds; the rules and the save round trip still run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015FPuYPS4T7QuEwjNu22rXD
This commit is contained in:
@@ -10,6 +10,15 @@
|
|||||||
|
|
||||||
#include "wiringrules.h"
|
#include "wiringrules.h"
|
||||||
|
|
||||||
|
// The checks that drive QElectroTech through a script (--run) need a
|
||||||
|
// build with scripting; without it --run is not an option and the
|
||||||
|
// process never exits (QET_HAS_SCRIPTING, top-level CMakeLists.txt).
|
||||||
|
#ifdef QET_HAS_SCRIPTING
|
||||||
|
# define SKIP_WITHOUT_SCRIPTING
|
||||||
|
#else
|
||||||
|
# define SKIP_WITHOUT_SCRIPTING QSKIP("built without scripting: --run is not available")
|
||||||
|
#endif
|
||||||
|
|
||||||
// How many wires a terminal may take (discussion #1158). The rules are
|
// How many wires a terminal may take (discussion #1158). The rules are
|
||||||
// tested on their own; the project setting and the refusal are tested
|
// tested on their own; the project setting and the refusal are tested
|
||||||
// through the real binary: --resave keeps a <wiring_rules> element and
|
// through the real binary: --resave keeps a <wiring_rules> element and
|
||||||
@@ -243,6 +252,7 @@ private slots:
|
|||||||
|
|
||||||
void wirePastTheLimitIsRefused()
|
void wirePastTheLimitIsRefused()
|
||||||
{
|
{
|
||||||
|
SKIP_WITHOUT_SCRIPTING;
|
||||||
// Without a rule the wire is drawn, as on master
|
// Without a rule the wire is drawn, as on master
|
||||||
QCOMPARE(addWireToWiredTerminal(QFINDTESTDATA("fixtures/qet_bug_repro_resaved.qet"), false),
|
QCOMPARE(addWireToWiredTerminal(QFINDTESTDATA("fixtures/qet_bug_repro_resaved.qet"), false),
|
||||||
QStringLiteral("true"));
|
QStringLiteral("true"));
|
||||||
|
|||||||
Reference in New Issue
Block a user