plugin_test.go 780 B

1234567891011121314151617181920212223242526272829303132
  1. package cluster
  2. import (
  3. "time"
  4. "github.com/google/uuid"
  5. "github.com/langgenius/dify-plugin-daemon/internal/types/entities"
  6. "github.com/langgenius/dify-plugin-daemon/internal/types/entities/plugin_entities"
  7. )
  8. func getRandomPluginRuntime() entities.PluginRuntime {
  9. return entities.PluginRuntime{
  10. Config: plugin_entities.PluginDeclaration{
  11. Name: uuid.New().String(),
  12. Version: "0.0.1",
  13. Type: plugin_entities.PluginType,
  14. Author: "Yeuoly",
  15. CreatedAt: time.Now(),
  16. Plugins: []string{"test"},
  17. },
  18. }
  19. }
  20. // func TestPluginScheduleLifetime(t *testing.T) {
  21. // plugin := getRandomPluginRuntime()
  22. // cluster, err := createSimulationCluster(1)
  23. // if err != nil {
  24. // t.Errorf("create simulation cluster failed: %v", err)
  25. // return
  26. // }
  27. // }