feat(core): implement cordis configuration extension and migrate all plugins

This commit is contained in:
ryan
2026-08-29 10:53:53 +08:00
parent b43c429544
commit ed8491addf
74 changed files with 1354 additions and 1145 deletions
+15
View File
@@ -7,9 +7,24 @@ import (
"testing"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
func TestNextUint64ID(t *testing.T) {
require.NoError(t, Init(1))
id := NextUint64ID()
assert.NotZero(t, id)
}
func TestNextUint64ID_PanicsWhenNotInitialized(t *testing.T) {
mu.Lock()
node = nil
mu.Unlock()
assert.PanicsWithError(t, ErrNotInitialized.Error(), func() {
NextUint64ID()
})
// Restore initialization for other tests
require.NoError(t, Init(1))
}