Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for NewTestExamplePlugin (0.31 sec)

  1. pkg/kubelet/pluginmanager/pluginwatcher/plugin_watcher_test.go

    	newWatcher(t, socketDir, dsw, wait.NeverStop)
    
    	for i := 0; i < 10; i++ {
    		socketPath := filepath.Join(socketDir, fmt.Sprintf("plugin-%d.sock", i))
    		pluginName := fmt.Sprintf("example-plugin-%d", i)
    
    		p := NewTestExamplePlugin(pluginName, registerapi.DevicePlugin, socketPath, supportedVersions...)
    		require.NoError(t, p.Serve("v1beta1", "v1beta2"))
    
    		pluginInfo := GetPluginInfo(p)
    		waitForRegistration(t, pluginInfo.SocketPath, dsw)
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Aug 04 06:56:50 UTC 2023
    - 8K bytes
    - Viewed (0)
  2. pkg/kubelet/pluginmanager/pluginwatcher/example_plugin.go

    }
    
    // NewExamplePlugin returns an initialized examplePlugin instance
    func NewExamplePlugin() *examplePlugin {
    	return &examplePlugin{}
    }
    
    // NewTestExamplePlugin returns an initialized examplePlugin instance for testing
    func NewTestExamplePlugin(pluginName string, pluginType string, endpoint string, advertisedVersions ...string) *examplePlugin {
    	return &examplePlugin{
    		pluginName:         pluginName,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 10 07:44:16 UTC 2021
    - 5K bytes
    - Viewed (0)
  3. pkg/kubelet/pluginmanager/reconciler/reconciler_test.go

    	stopChan := make(chan struct{})
    	defer close(stopChan)
    	go reconciler.Run(stopChan)
    	socketPath := filepath.Join(socketDir, "plugin.sock")
    	pluginName := fmt.Sprintf("example-plugin")
    	p := pluginwatcher.NewTestExamplePlugin(pluginName, registerapi.DevicePlugin, socketPath, supportedVersions...)
    	require.NoError(t, p.Serve("v1beta1", "v1beta2"))
    	defer func() {
    		require.NoError(t, p.Stop())
    	}()
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Mar 16 14:21:15 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  4. pkg/kubelet/pluginmanager/plugin_manager_test.go

    		socketPath := filepath.Join(pluginDir, fmt.Sprintf("plugin-%d.sock", i))
    
    		// Add a new plugin
    		pluginName := fmt.Sprintf("example-plugin-%d", i)
    		p := pluginwatcher.NewTestExamplePlugin(pluginName, registerapi.DevicePlugin, socketPath, supportedVersions...)
    		require.NoError(t, p.Serve("v1beta1", "v1beta2"))
    
    		// Verify that the plugin is registered
    		waitForRegistration(t, fakeHandler, pluginName)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 04 06:25:43 UTC 2024
    - 4.4K bytes
    - Viewed (0)
Back to top