- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 24 for testPrinter (0.2 sec)
-
cmd/kubeadm/app/util/output/output.go
Printf(format string, args ...interface{}) (n int, err error) Println(args ...interface{}) (n int, err error) } // TextPrinter implements Printer interface for generic text output type TextPrinter struct { } // PrintObj is an implementation of ResourcePrinter.PrintObj that prints object func (tp *TextPrinter) PrintObj(obj runtime.Object, writer io.Writer) error { _, err := fmt.Fprintf(writer, "%+v\n", obj) return err }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Apr 19 08:22:45 UTC 2024 - 8K bytes - Viewed (0) -
pkg/kube/kclient/clienttest/test_helpers.go
c kclient.ReadWriter[T] t test.Failer TestWriter[T] } type TestWriter[T controllers.Object] struct { c kclient.Writer[T] t test.Failer } func (t TestClient[T]) Get(name, namespace string) T { return t.c.Get(name, namespace) } func (t TestClient[T]) List(namespace string, selector klabels.Selector) []T { return t.c.List(namespace, selector) } func (t TestWriter[T]) Create(object T) T { t.t.Helper()
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri Feb 23 19:18:21 UTC 2024 - 3.9K bytes - Viewed (0) -
src/go/doc/comment/text.go
// license that can be found in the LICENSE file. package comment import ( "bytes" "fmt" "sort" "strings" "unicode/utf8" ) // A textPrinter holds the state needed for printing a Doc as plain text. type textPrinter struct { *Printer long strings.Builder prefix string codePrefix string width int } // Text returns a textual formatting of the [Doc].
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 12:02:03 UTC 2023 - 8.8K bytes - Viewed (0) -
src/cmd/go/internal/modfetch/codehost/git_test.go
func newTestWriter(t testing.TB) *testWriter { w := &testWriter{t: t} t.Cleanup(func() { w.mu.Lock() defer w.mu.Unlock() if b := w.buf.Bytes(); len(b) > 0 { w.t.Logf("%s", b) w.buf.Reset() } }) return w } func (w *testWriter) Write(p []byte) (int, error) { w.mu.Lock() defer w.mu.Unlock() n, err := w.buf.Write(p) if b := w.buf.Bytes(); len(b) > 0 && b[len(b)-1] == '\n' {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Dec 14 19:46:23 UTC 2023 - 18.9K bytes - Viewed (0) -
operator/pkg/util/progress/progress.go
return prefix + msg } // For testing only var testWriter *io.Writer func createBar() *pb.ProgressBar { // Don't set a total and use Static so we can explicitly control when you write. This is needed // for handling the multiline issues. bar := pb.New(0) bar.Set(pb.Static, true) if testWriter != nil { bar.SetWriter(*testWriter) } bar.Start()
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 14 19:23:44 UTC 2024 - 6.2K bytes - Viewed (0) -
cmd/kubeadm/app/cmd/upgrade/common_test.go
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Feb 29 05:14:21 UTC 2024 - 5.5K bytes - Viewed (0) -
operator/pkg/util/progress/progress_test.go
package progress import ( "bytes" "io" "testing" "istio.io/istio/operator/pkg/name" ) func TestProgressLog(t *testing.T) { buf := bytes.NewBuffer(nil) testBuf := io.Writer(buf) testWriter = &testBuf expected := "" expect := func(e string) { t.Helper() // In buffer mode we don't overwrite old data, so we are constantly appending to the expected newExpected := expected + "\n" + e
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 14 19:23:44 UTC 2024 - 2.1K bytes - Viewed (0) -
.gitignore
pilot/pkg/kube/config pilot/pkg/proxy/envoy/envoy # lint lintconfig.gen.json .istiorc .istiorc.mk # codegen stuff bin/adapterlinter bin/protoc-gen-gogoslick* bin/protoc-min-version* bin/protoc-gen-docs* bin/testlinter bin/envvarlinter bin/istioctl *.orig # Avoid accidental istio.VERSION changes istio.VERSION LICENSES.txt # Proxy generated proxy config in integration test tests/integration/component/proxy/envoy.conf
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 21 21:20:01 UTC 2024 - 1.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/io/CharSourceTest.java
assertEquals(ImmutableList.of("foo"), list); assertTrue(lines.wasStreamOpened() && lines.wasStreamClosed()); } public void testCopyToAppendable_doesNotCloseIfWriter() throws IOException { TestWriter writer = new TestWriter(); assertFalse(writer.closed()); source.copyTo(writer); assertFalse(writer.closed()); } public void testClosesOnErrors_copyingToCharSinkThatThrows() {
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Tue May 07 15:26:58 UTC 2024 - 10.5K bytes - Viewed (0) -
src/internal/weak/pointer_test.go
"testing" ) type T struct { // N.B. This must contain a pointer, otherwise the weak handle might get placed // in a tiny block making the tests in this package flaky. t *T a int } func TestPointer(t *testing.T) { bt := new(T) wt := weak.Make(bt) if st := wt.Strong(); st != bt { t.Fatalf("weak pointer is not the same as strong pointer: %p vs. %p", st, bt) } // bt is still referenced. runtime.GC()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 18 21:25:11 UTC 2024 - 3.1K bytes - Viewed (0)