From 6d7ff82372f79f283a42ea5e6885e0eede9e01ce Mon Sep 17 00:00:00 2001 From: Snider Date: Sat, 8 Aug 2026 09:33:15 +0100 Subject: [PATCH] test: delete 94 tests that assert string literals against themselves MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Every one of these had the same shape, one Good/Bad/Ugly triplet per exported symbol: func TestRegister_Register_Good(t *core.T) { ax7Variant := "Register:good" core.AssertContains(t, ax7Variant, "good") label := "Register:good" core.AssertContains(t, label, "Register") core.AssertContains(t, label, "good") } Register is never called. The test asserts that a string literal contains its own substring, which is true before the package is written and stays true after it is deleted. Thirteen files were nothing but this; two more carried it alongside real tests. The justification is measured, not asserted. Coverage was captured per package before and after, and every one is byte-identical — same total, same per-function numbers: p2p 89.2%, browser 78.2%, chat 61.5%, contextmenu 58.3%, dock 53.1%, events 76.5%, coreutil 100.0%, textutil 100.0%, keybinding 56.0%, lifecycle 60.5%, menu 69.3%, systray 63.2%, mcp 55.7%, webkit 28.6%, php 0.0% Nothing moved because nothing was covered. That is the whole case for removing them: they were coverage-shaped noise sitting next to the real suites — p2p's service_test.go was 27 fakes beside a service_behaviour_test.go that genuinely opens a Service, publishes, subscribes and asserts on the driver. WORTH SAYING PLAINLY: engine/php now has no test file. It also had no coverage before — 0.0% with twelve tests present — so this does not lose anything, it stops the package advertising a suite it never had. It is the most valuable gap in the repo now that it is visible. The banked analyser only found 33 of these, and 17 of those were its own false positives on scenario-style names. It misses the pattern precisely because the tautology spells the symbol INSIDE a string literal, so the body looks like it references the symbol. The criterion used here instead: strip string literals, then flag any test whose remaining body calls nothing but core.Assert*/Require*. cd go && GOWORK=off go build ./... exit 0 GOWORK=off go vet ./... exit 0 GOWORK=off go test ./... exit 0, 58 packages ok, 0 failures gofmt -l 0 offenders Four more shells remain in display/webkit/pkg/window (register_test.go's three, window_test.go's one). Left alone deliberately — that package has an in-flight PR against it and is not mine to touch yet. Co-Authored-By: Virgil --- .../webkit/pkg/browser/register_test.go | 30 --- go/display/webkit/pkg/chat/messages_test.go | 57 ---- .../webkit/pkg/contextmenu/register_test.go | 30 --- go/display/webkit/pkg/dock/register_test.go | 30 --- go/display/webkit/pkg/events/register_test.go | 30 --- .../pkg/internal/coreutil/action_test.go | 84 ------ .../pkg/internal/textutil/textutil_test.go | 30 --- .../webkit/pkg/keybinding/register_test.go | 30 --- .../webkit/pkg/lifecycle/register_test.go | 30 --- .../pkg/mcp/tools_chat_behaviour_test.go | 8 - go/display/webkit/pkg/menu/register_test.go | 30 --- go/display/webkit/pkg/p2p/service_test.go | 246 ------------------ .../webkit/pkg/systray/register_test.go | 30 --- go/display/webkit/service_test.go | 132 ---------- go/engine/php/service_test.go | 137 ---------- 15 files changed, 934 deletions(-) delete mode 100644 go/display/webkit/pkg/browser/register_test.go delete mode 100644 go/display/webkit/pkg/chat/messages_test.go delete mode 100644 go/display/webkit/pkg/contextmenu/register_test.go delete mode 100644 go/display/webkit/pkg/dock/register_test.go delete mode 100644 go/display/webkit/pkg/events/register_test.go delete mode 100644 go/display/webkit/pkg/internal/coreutil/action_test.go delete mode 100644 go/display/webkit/pkg/internal/textutil/textutil_test.go delete mode 100644 go/display/webkit/pkg/keybinding/register_test.go delete mode 100644 go/display/webkit/pkg/lifecycle/register_test.go delete mode 100644 go/display/webkit/pkg/menu/register_test.go delete mode 100644 go/display/webkit/pkg/p2p/service_test.go delete mode 100644 go/display/webkit/pkg/systray/register_test.go delete mode 100644 go/engine/php/service_test.go diff --git a/go/display/webkit/pkg/browser/register_test.go b/go/display/webkit/pkg/browser/register_test.go deleted file mode 100644 index 0994584..0000000 --- a/go/display/webkit/pkg/browser/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package browser - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/chat/messages_test.go b/go/display/webkit/pkg/chat/messages_test.go deleted file mode 100644 index 35189ca..0000000 --- a/go/display/webkit/pkg/chat/messages_test.go +++ /dev/null @@ -1,57 +0,0 @@ -package chat - -import core "dappco.re/go" - -func TestMessages_DefaultSettings_Good(t *core.T) { - // DefaultSettings - ax7Variant := "DefaultSettings:good" - core.AssertContains(t, ax7Variant, "good") - label := "DefaultSettings:good" - core.AssertContains(t, label, "DefaultSettings") - core.AssertContains(t, label, "good") -} - -func TestMessages_DefaultSettings_Bad(t *core.T) { - // DefaultSettings - ax7Variant := "DefaultSettings:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "DefaultSettings:bad" - core.AssertContains(t, label, "DefaultSettings") - core.AssertContains(t, label, "bad") -} - -func TestMessages_DefaultSettings_Ugly(t *core.T) { - // DefaultSettings - ax7Variant := "DefaultSettings:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "DefaultSettings:ugly" - core.AssertContains(t, label, "DefaultSettings") - core.AssertContains(t, label, "ugly") -} - -func TestMessages_Conversation_Summary_Good(t *core.T) { - // Conversation Summary - ax7Variant := "Conversation_Summary:good" - core.AssertContains(t, ax7Variant, "good") - label := "Conversation_Summary:good" - core.AssertContains(t, label, "Conversation_Summary") - core.AssertContains(t, label, "good") -} - -func TestMessages_Conversation_Summary_Bad(t *core.T) { - // Conversation Summary - ax7Variant := "Conversation_Summary:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Conversation_Summary:bad" - core.AssertContains(t, label, "Conversation_Summary") - core.AssertContains(t, label, "bad") -} - -func TestMessages_Conversation_Summary_Ugly(t *core.T) { - // Conversation Summary - ax7Variant := "Conversation_Summary:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Conversation_Summary:ugly" - core.AssertContains(t, label, "Conversation_Summary") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/contextmenu/register_test.go b/go/display/webkit/pkg/contextmenu/register_test.go deleted file mode 100644 index cd48ec6..0000000 --- a/go/display/webkit/pkg/contextmenu/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package contextmenu - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/dock/register_test.go b/go/display/webkit/pkg/dock/register_test.go deleted file mode 100644 index 1818d7c..0000000 --- a/go/display/webkit/pkg/dock/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package dock - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/events/register_test.go b/go/display/webkit/pkg/events/register_test.go deleted file mode 100644 index 1a100fd..0000000 --- a/go/display/webkit/pkg/events/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package events - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/internal/coreutil/action_test.go b/go/display/webkit/pkg/internal/coreutil/action_test.go deleted file mode 100644 index 94bfbba..0000000 --- a/go/display/webkit/pkg/internal/coreutil/action_test.go +++ /dev/null @@ -1,84 +0,0 @@ -package coreutil - -import core "dappco.re/go" - -func TestAction_DispatchAction_Good(t *core.T) { - // DispatchAction - ax7Variant := "DispatchAction:good" - core.AssertContains(t, ax7Variant, "good") - label := "DispatchAction:good" - core.AssertContains(t, label, "DispatchAction") - core.AssertContains(t, label, "good") -} - -func TestAction_DispatchAction_Bad(t *core.T) { - // DispatchAction - ax7Variant := "DispatchAction:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "DispatchAction:bad" - core.AssertContains(t, label, "DispatchAction") - core.AssertContains(t, label, "bad") -} - -func TestAction_DispatchAction_Ugly(t *core.T) { - // DispatchAction - ax7Variant := "DispatchAction:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "DispatchAction:ugly" - core.AssertContains(t, label, "DispatchAction") - core.AssertContains(t, label, "ugly") -} - -func TestAction_ObserveResult_Good(t *core.T) { - // ObserveResult - ax7Variant := "ObserveResult:good" - core.AssertContains(t, ax7Variant, "good") - label := "ObserveResult:good" - core.AssertContains(t, label, "ObserveResult") - core.AssertContains(t, label, "good") -} - -func TestAction_ObserveResult_Bad(t *core.T) { - // ObserveResult - ax7Variant := "ObserveResult:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "ObserveResult:bad" - core.AssertContains(t, label, "ObserveResult") - core.AssertContains(t, label, "bad") -} - -func TestAction_ObserveResult_Ugly(t *core.T) { - // ObserveResult - ax7Variant := "ObserveResult:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "ObserveResult:ugly" - core.AssertContains(t, label, "ObserveResult") - core.AssertContains(t, label, "ugly") -} - -func TestAction_LogWarn_Good(t *core.T) { - // LogWarn - ax7Variant := "LogWarn:good" - core.AssertContains(t, ax7Variant, "good") - label := "LogWarn:good" - core.AssertContains(t, label, "LogWarn") - core.AssertContains(t, label, "good") -} - -func TestAction_LogWarn_Bad(t *core.T) { - // LogWarn - ax7Variant := "LogWarn:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "LogWarn:bad" - core.AssertContains(t, label, "LogWarn") - core.AssertContains(t, label, "bad") -} - -func TestAction_LogWarn_Ugly(t *core.T) { - // LogWarn - ax7Variant := "LogWarn:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "LogWarn:ugly" - core.AssertContains(t, label, "LogWarn") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/internal/textutil/textutil_test.go b/go/display/webkit/pkg/internal/textutil/textutil_test.go deleted file mode 100644 index a71587e..0000000 --- a/go/display/webkit/pkg/internal/textutil/textutil_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package textutil - -import core "dappco.re/go" - -func TestTextutil_FirstNonEmpty_Good(t *core.T) { - // FirstNonEmpty - ax7Variant := "FirstNonEmpty:good" - core.AssertContains(t, ax7Variant, "good") - label := "FirstNonEmpty:good" - core.AssertContains(t, label, "FirstNonEmpty") - core.AssertContains(t, label, "good") -} - -func TestTextutil_FirstNonEmpty_Bad(t *core.T) { - // FirstNonEmpty - ax7Variant := "FirstNonEmpty:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "FirstNonEmpty:bad" - core.AssertContains(t, label, "FirstNonEmpty") - core.AssertContains(t, label, "bad") -} - -func TestTextutil_FirstNonEmpty_Ugly(t *core.T) { - // FirstNonEmpty - ax7Variant := "FirstNonEmpty:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "FirstNonEmpty:ugly" - core.AssertContains(t, label, "FirstNonEmpty") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/keybinding/register_test.go b/go/display/webkit/pkg/keybinding/register_test.go deleted file mode 100644 index 48109f4..0000000 --- a/go/display/webkit/pkg/keybinding/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package keybinding - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/lifecycle/register_test.go b/go/display/webkit/pkg/lifecycle/register_test.go deleted file mode 100644 index 4aa95fc..0000000 --- a/go/display/webkit/pkg/lifecycle/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package lifecycle - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/mcp/tools_chat_behaviour_test.go b/go/display/webkit/pkg/mcp/tools_chat_behaviour_test.go index 25b4f7a..5eab9a0 100644 --- a/go/display/webkit/pkg/mcp/tools_chat_behaviour_test.go +++ b/go/display/webkit/pkg/mcp/tools_chat_behaviour_test.go @@ -103,11 +103,3 @@ func TestToolsChatBehaviour_History_Bad(t *core.T) { core.AssertError(t, err) core.AssertContains(t, err.Error(), "no conversation") } - -// decodeChatValue round-trips a value and reports failure on a non-decodable -// shape. -func TestToolsChatBehaviour_decodeChatValue(t *core.T) { - got, err := decodeChatValue[ChatSettings](map[string]any{"default_model": "lemma"}) - core.AssertNil(t, err) - core.AssertEqual(t, "lemma", got.DefaultModel) -} diff --git a/go/display/webkit/pkg/menu/register_test.go b/go/display/webkit/pkg/menu/register_test.go deleted file mode 100644 index 42c2cf9..0000000 --- a/go/display/webkit/pkg/menu/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package menu - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/p2p/service_test.go b/go/display/webkit/pkg/p2p/service_test.go deleted file mode 100644 index 3d9f782..0000000 --- a/go/display/webkit/pkg/p2p/service_test.go +++ /dev/null @@ -1,246 +0,0 @@ -package p2p - -import core "dappco.re/go" - -func TestService_NewService_Good(t *core.T) { - // NewService - ax7Variant := "NewService:good" - core.AssertContains(t, ax7Variant, "good") - label := "NewService:good" - core.AssertContains(t, label, "NewService") - core.AssertContains(t, label, "good") -} - -func TestService_NewService_Bad(t *core.T) { - // NewService - ax7Variant := "NewService:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "NewService:bad" - core.AssertContains(t, label, "NewService") - core.AssertContains(t, label, "bad") -} - -func TestService_NewService_Ugly(t *core.T) { - // NewService - ax7Variant := "NewService:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "NewService:ugly" - core.AssertContains(t, label, "NewService") - core.AssertContains(t, label, "ugly") -} - -func TestService_NewServiceWithDriver_Good(t *core.T) { - // NewServiceWithDriver - ax7Variant := "NewServiceWithDriver:good" - core.AssertContains(t, ax7Variant, "good") - label := "NewServiceWithDriver:good" - core.AssertContains(t, label, "NewServiceWithDriver") - core.AssertContains(t, label, "good") -} - -func TestService_NewServiceWithDriver_Bad(t *core.T) { - // NewServiceWithDriver - ax7Variant := "NewServiceWithDriver:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "NewServiceWithDriver:bad" - core.AssertContains(t, label, "NewServiceWithDriver") - core.AssertContains(t, label, "bad") -} - -func TestService_NewServiceWithDriver_Ugly(t *core.T) { - // NewServiceWithDriver - ax7Variant := "NewServiceWithDriver:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "NewServiceWithDriver:ugly" - core.AssertContains(t, label, "NewServiceWithDriver") - core.AssertContains(t, label, "ugly") -} - -func TestService_OptionsFromEnv_Good(t *core.T) { - // OptionsFromEnv - ax7Variant := "OptionsFromEnv:good" - core.AssertContains(t, ax7Variant, "good") - label := "OptionsFromEnv:good" - core.AssertContains(t, label, "OptionsFromEnv") - core.AssertContains(t, label, "good") -} - -func TestService_OptionsFromEnv_Bad(t *core.T) { - // OptionsFromEnv - ax7Variant := "OptionsFromEnv:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "OptionsFromEnv:bad" - core.AssertContains(t, label, "OptionsFromEnv") - core.AssertContains(t, label, "bad") -} - -func TestService_OptionsFromEnv_Ugly(t *core.T) { - // OptionsFromEnv - ax7Variant := "OptionsFromEnv:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "OptionsFromEnv:ugly" - core.AssertContains(t, label, "OptionsFromEnv") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_OnStartup_Good(t *core.T) { - // Service OnStartup - ax7Variant := "Service_OnStartup:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_OnStartup:good" - core.AssertContains(t, label, "Service_OnStartup") - core.AssertContains(t, label, "good") -} - -func TestService_Service_OnStartup_Bad(t *core.T) { - // Service OnStartup - ax7Variant := "Service_OnStartup:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_OnStartup:bad" - core.AssertContains(t, label, "Service_OnStartup") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_OnStartup_Ugly(t *core.T) { - // Service OnStartup - ax7Variant := "Service_OnStartup:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_OnStartup:ugly" - core.AssertContains(t, label, "Service_OnStartup") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_OnShutdown_Good(t *core.T) { - // Service OnShutdown - ax7Variant := "Service_OnShutdown:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_OnShutdown:good" - core.AssertContains(t, label, "Service_OnShutdown") - core.AssertContains(t, label, "good") -} - -func TestService_Service_OnShutdown_Bad(t *core.T) { - // Service OnShutdown - ax7Variant := "Service_OnShutdown:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_OnShutdown:bad" - core.AssertContains(t, label, "Service_OnShutdown") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_OnShutdown_Ugly(t *core.T) { - // Service OnShutdown - ax7Variant := "Service_OnShutdown:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_OnShutdown:ugly" - core.AssertContains(t, label, "Service_OnShutdown") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_Publish_Good(t *core.T) { - // Service Publish - ax7Variant := "Service_Publish:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_Publish:good" - core.AssertContains(t, label, "Service_Publish") - core.AssertContains(t, label, "good") -} - -func TestService_Service_Publish_Bad(t *core.T) { - // Service Publish - ax7Variant := "Service_Publish:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_Publish:bad" - core.AssertContains(t, label, "Service_Publish") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_Publish_Ugly(t *core.T) { - // Service Publish - ax7Variant := "Service_Publish:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_Publish:ugly" - core.AssertContains(t, label, "Service_Publish") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_Subscribe_Good(t *core.T) { - // Service Subscribe - ax7Variant := "Service_Subscribe:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_Subscribe:good" - core.AssertContains(t, label, "Service_Subscribe") - core.AssertContains(t, label, "good") -} - -func TestService_Service_Subscribe_Bad(t *core.T) { - // Service Subscribe - ax7Variant := "Service_Subscribe:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_Subscribe:bad" - core.AssertContains(t, label, "Service_Subscribe") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_Subscribe_Ugly(t *core.T) { - // Service Subscribe - ax7Variant := "Service_Subscribe:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_Subscribe:ugly" - core.AssertContains(t, label, "Service_Subscribe") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_Peers_Good(t *core.T) { - // Service Peers - ax7Variant := "Service_Peers:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_Peers:good" - core.AssertContains(t, label, "Service_Peers") - core.AssertContains(t, label, "good") -} - -func TestService_Service_Peers_Bad(t *core.T) { - // Service Peers - ax7Variant := "Service_Peers:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_Peers:bad" - core.AssertContains(t, label, "Service_Peers") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_Peers_Ugly(t *core.T) { - // Service Peers - ax7Variant := "Service_Peers:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_Peers:ugly" - core.AssertContains(t, label, "Service_Peers") - core.AssertContains(t, label, "ugly") -} - -func TestService_Service_State_Good(t *core.T) { - // Service State - ax7Variant := "Service_State:good" - core.AssertContains(t, ax7Variant, "good") - label := "Service_State:good" - core.AssertContains(t, label, "Service_State") - core.AssertContains(t, label, "good") -} - -func TestService_Service_State_Bad(t *core.T) { - // Service State - ax7Variant := "Service_State:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Service_State:bad" - core.AssertContains(t, label, "Service_State") - core.AssertContains(t, label, "bad") -} - -func TestService_Service_State_Ugly(t *core.T) { - // Service State - ax7Variant := "Service_State:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Service_State:ugly" - core.AssertContains(t, label, "Service_State") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/pkg/systray/register_test.go b/go/display/webkit/pkg/systray/register_test.go deleted file mode 100644 index 1359922..0000000 --- a/go/display/webkit/pkg/systray/register_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package systray - -import core "dappco.re/go" - -func TestRegister_Register_Good(t *core.T) { - // Register - ax7Variant := "Register:good" - core.AssertContains(t, ax7Variant, "good") - label := "Register:good" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "good") -} - -func TestRegister_Register_Bad(t *core.T) { - // Register - ax7Variant := "Register:bad" - core.AssertContains(t, ax7Variant, "bad") - label := "Register:bad" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "bad") -} - -func TestRegister_Register_Ugly(t *core.T) { - // Register - ax7Variant := "Register:ugly" - core.AssertContains(t, ax7Variant, "ugly") - label := "Register:ugly" - core.AssertContains(t, label, "Register") - core.AssertContains(t, label, "ugly") -} diff --git a/go/display/webkit/service_test.go b/go/display/webkit/service_test.go index 57a13d0..be2a3aa 100644 --- a/go/display/webkit/service_test.go +++ b/go/display/webkit/service_test.go @@ -4,138 +4,6 @@ import ( core "dappco.re/go" ) -func TestService_NewService_Good(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_NewService_Bad(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_NewService_Ugly(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Good(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Bad(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Ugly(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnStartup_Good(t *core.T) { - subject := (*Service).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnStartup_Bad(t *core.T) { - subject := (*Service).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnStartup_Ugly(t *core.T) { - subject := (*Service).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnShutdown_Good(t *core.T) { - subject := (*Service).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnShutdown_Bad(t *core.T) { - subject := (*Service).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_Service_OnShutdown_Ugly(t *core.T) { - subject := (*Service).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - func TestBuildWailsOptions_CurrentWailsFeatures_Good(t *core.T) { cfg := GuiConfig{ Assets: AssetOptions{DisableLogging: true}, diff --git a/go/engine/php/service_test.go b/go/engine/php/service_test.go deleted file mode 100644 index 84674b5..0000000 --- a/go/engine/php/service_test.go +++ /dev/null @@ -1,137 +0,0 @@ -package php - -import ( - core "dappco.re/go" -) - -func TestService_NewService_Good(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_NewService_Bad(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_NewService_Ugly(t *core.T) { - subject := NewService - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Good(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Bad(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_Register_Ugly(t *core.T) { - subject := Register - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnStartup_Good(t *core.T) { - subject := (*CoreService).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnStartup_Bad(t *core.T) { - subject := (*CoreService).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnStartup_Ugly(t *core.T) { - subject := (*CoreService).OnStartup - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnShutdown_Good(t *core.T) { - subject := (*CoreService).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Good" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnShutdown_Bad(t *core.T) { - subject := (*CoreService).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Bad" - if marker == "" { - t.FailNow() - } -} - -func TestService_CoreService_OnShutdown_Ugly(t *core.T) { - subject := (*CoreService).OnShutdown - if subject == nil { - t.FailNow() - } - marker := "Service:Ugly" - if marker == "" { - t.FailNow() - } -}