mirror of
https://github.com/logos-messaging/logos-messaging-go-bindings.git
synced 2026-01-07 08:23:06 +00:00
Fix part2 review points
This commit is contained in:
parent
d973e451dc
commit
b81b4370af
@ -13,12 +13,15 @@ import (
|
||||
func TestBasicWakuNodes(t *testing.T) {
|
||||
utilities.Debug("Create logger instance")
|
||||
logger, _ := zap.NewDevelopment()
|
||||
|
||||
nodeCfg := *utilities.DefaultWakuConfig
|
||||
nodeCfg.Relay = true
|
||||
|
||||
utilities.Debug("Starting the WakuNodeWrapper")
|
||||
node, err := testlibs.Wrappers_StartWakuNode(&nodeCfg, logger.Named("node"))
|
||||
require.NoError(t, err, "Failed to create the WakuNodeWrapper")
|
||||
|
||||
// Use defer to ensure proper cleanup
|
||||
defer func() {
|
||||
utilities.Debug("Stopping and destroying Node")
|
||||
node.Wrappers_StopAndDestroy()
|
||||
@ -27,6 +30,6 @@ func TestBasicWakuNodes(t *testing.T) {
|
||||
|
||||
time.Sleep(2 * time.Second)
|
||||
|
||||
err = node.Wrappers_StopAndDestroy()
|
||||
require.NoError(t, err, "Failed to stop+destroy Node")
|
||||
// No need for another StopAndDestroy here, defer already handles cleanup
|
||||
utilities.Debug("Test completed successfully")
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user