Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 51 for assertj (0.31 sec)

  1. cmd/object-handlers_test.go

    	credentials auth.Credentials, t *testing.T,
    ) {
    	objectName := "test-object"
    	// set of byte data for PutObject.
    	// object has to be created before running tests for HeadObject.
    	// this is required even to assert the HeadObject data,
    	// since dataInserted === dataFetched back is a primary criteria for any object storage this assertion is critical.
    	bytesData := []struct {
    		byteData []byte
    	}{
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 160K bytes
    - Viewed (0)
  2. cni/pkg/nodeagent/healthServer_test.go

    	installReady.Store(true)
    	watchReady.Store(true)
    	assert.Equal(t, installReady.Load(), true)
    	assert.Equal(t, watchReady.Load(), true)
    
    	makeReq(t, server.URL, constants.LivenessEndpoint, http.StatusOK)
    	makeReq(t, server.URL, constants.ReadinessEndpoint, http.StatusOK)
    
    	watchReady.Store(false)
    	assert.Equal(t, watchReady.Load(), false)
    	assert.Equal(t, installReady.Load(), true)
    
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Fri Jan 26 20:34:28 GMT 2024
    - 2K bytes
    - Viewed (0)
  3. cni/pkg/repair/repair_test.go

    			tt.config.LabelPods = true
    			c, err := NewRepairController(tt.client, tt.config)
    			assert.NoError(t, err)
    			t.Cleanup(func() {
    				assert.NoError(t, c.queue.WaitForClose(time.Second))
    			})
    			stop := test.NewStop(t)
    			tt.client.RunAndWait(stop)
    			go c.Run(stop)
    			kube.WaitForCacheSync("test", stop, c.queue.HasSynced)
    
    			assert.EventuallyEqual(t, func() map[string]string {
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Tue Oct 24 03:31:28 GMT 2023
    - 10.6K bytes
    - Viewed (0)
  4. cni/pkg/nodeagent/ztunnelserver_test.go

    	mt.Assert(ztunnelConnected.Name(), nil, monitortest.Exactly(1))
    
    	// we should get the fd to dev null. note that we can't assert the fd number
    	// as the kernel may have given us a different number that refers to the same file.
    	assert.Equal(t, len(fds), 1)
    	// in theory we should close the fd, but it's just a test..
    
    	assert.Equal(t, m.Payload.(*zdsapi.WorkloadRequest_Add).Add.Uid, uid)
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Fri Apr 12 21:47:31 GMT 2024
    - 8.6K bytes
    - Viewed (0)
  5. cni/pkg/install/binaries_test.go

    				contents := file.AsStringOrFail(t, filepath.Join(targetDir, filename))
    				assert.Equal(t, contents, expectedContents)
    
    				wasCopied := false
    				for _, bin := range binariesCopied.UnsortedList() {
    					if bin == filename {
    						wasCopied = true
    					}
    				}
    				assert.Equal(t, wasCopied, true)
    			}
    		})
    	}
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Thu Jul 20 18:34:43 GMT 2023
    - 2.3K bytes
    - Viewed (0)
  6. cni/pkg/util/podutil_test.go

    	"istio.io/istio/pkg/test/util/assert"
    )
    
    func TestGetPodIPIfPodIPPresent(t *testing.T) {
    	pod := &corev1.Pod{
    		ObjectMeta: metav1.ObjectMeta{
    			Name:      "test",
    			Namespace: "test",
    		},
    		Spec: corev1.PodSpec{
    			NodeName: "derp",
    		},
    		Status: corev1.PodStatus{
    			PodIP: "11.1.1.12",
    		},
    	}
    
    	podIPs := GetPodIPsIfPresent(pod)
    	assert.Equal(t, len(podIPs), 1)
    }
    
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Fri Jan 26 20:34:28 GMT 2024
    - 1.7K bytes
    - Viewed (0)
  7. istioctl/pkg/writer/ztunnel/configdump/configdump_test.go

    				}
    			} else if len(cw.ztunnelDump.Workloads) != tt.wantConfigs {
    				t.Errorf("wanted %v configs loaded in got %v", tt.wantConfigs, len(cw.ztunnelDump.Workloads))
    			}
    			if tt.wantErr {
    				assert.Error(t, err)
    			} else {
    				assert.NoError(t, err)
    			}
    		})
    	}
    }
    
    func TestConfigWriter_PrintSecretSummary(t *testing.T) {
    	tests := []struct {
    		name               string
    		wantOutputSecret   string
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Fri Feb 02 18:21:48 GMT 2024
    - 3.6K bytes
    - Viewed (0)
  8. istioctl/pkg/writer/pilot/status_test.go

    			input := map[string]*discovery.DiscoveryResponse{}
    			for key, ss := range tt.input {
    				input[key] = ss
    			}
    
    			err := sw.PrintAll(input)
    			if tt.wantErr {
    				assert.Error(t, err)
    			} else {
    				assert.NoError(t, err)
    			}
    			want, _ := os.ReadFile(tt.want)
    			if err := util.Compare(got.Bytes(), want); err != nil {
    				t.Errorf(err.Error())
    			}
    		})
    	}
    }
    
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Fri Mar 08 08:38:19 GMT 2024
    - 6.5K bytes
    - Viewed (0)
  9. istioctl/pkg/proxyconfig/proxyconfig_test.go

    		Namespace: "default",
    	}))
    	cmd.SetArgs([]string{
    		"all",
    		"-f", "testdata/config_dump.json",
    	})
    	out := bytes.Buffer{}
    	cmd.SetOut(&out)
    	assert.NoError(t, cmd.Execute())
    	expected := util.ReadFile(t, "testdata/config_dump_summary.txt")
    
    	if err := assert.Compare(out.String(), string(expected)); err != nil {
    		t.Fatalf("Unexpected output for 'istioctl proxy-config all'\n got: %q\nwant: %q", out.String(), expected)
    	}
    }
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Wed Apr 10 21:51:29 GMT 2024
    - 8.9K bytes
    - Viewed (0)
  10. cmd/admin-handlers-users_test.go

    	}
    	groupInfo, err := s.adm.GetGroupDescription(ctx, group)
    	if err != nil {
    		c.Fatalf("group desc err: %v", err)
    	}
    	c.Assert(groupInfo.Name, group)
    	c.Assert(set.CreateStringSet(groupInfo.Members...), set.CreateStringSet(accessKey))
    	c.Assert(groupInfo.Policy, policy)
    	c.Assert(groupInfo.Status, string(madmin.GroupEnabled))
    
    	// 5. Disable/enable the group and verify that user access is revoked/restored.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Feb 12 16:36:16 GMT 2024
    - 45.7K bytes
    - Viewed (0)
Back to top