Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 16 of 16 for appendable (0.18 sec)

  1. cmd/xl-storage_windows_test.go

    	if err != nil {
    		t.Fatal(err)
    	}
    
    	err = fs.AppendFile(context.Background(), "voldir", "/file", []byte("hello"))
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	// Try to create a file that includes a file in its path components.
    	// In *nix, this returns syscall.ENOTDIR while in windows we receive the following error.
    	err = fs.AppendFile(context.Background(), "voldir", "/file/obj1", []byte("hello"))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed Nov 29 06:35:16 GMT 2023
    - 2.8K bytes
    - Viewed (0)
  2. cmd/xl-storage_test.go

    	// Create test files for further reading.
    	for i, appendFile := range appendFiles {
    		err = xlStorage.AppendFile(context.Background(), volume, appendFile.fileName, []byte("hello, world"))
    		if err != appendFile.expectedErr {
    			t.Fatalf("Creating file failed: %d %#v, expected: %s, got: %s", i+1, appendFile, appendFile.expectedErr, err)
    		}
    	}
    
    	{
    		buf := make([]byte, 5)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 11 17:45:28 GMT 2024
    - 66.7K bytes
    - Viewed (0)
  3. cmd/storage-interface.go

    	ListDir(ctx context.Context, origvolume, volume, dirPath string, count int) ([]string, error)
    	ReadFile(ctx context.Context, volume string, path string, offset int64, buf []byte, verifier *BitrotVerifier) (n int64, err error)
    	AppendFile(ctx context.Context, volume string, path string, buf []byte) (err error)
    	CreateFile(ctx context.Context, origvolume, olume, path string, size int64, reader io.Reader) error
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 4.9K bytes
    - Viewed (0)
  4. internal/ioutil/ioutil_test.go

    	defer os.Remove(name2)
    	f.WriteString("bbbbbbbbbb")
    	f.Close()
    
    	if err = AppendFile(name1, name2, false); err != nil {
    		t.Error(err)
    	}
    
    	b, err := os.ReadFile(name1)
    	if err != nil {
    		t.Error(err)
    	}
    
    	expected := "aaaaaaaaaabbbbbbbbbb"
    	if string(b) != expected {
    		t.Errorf("AppendFile() failed, expected: %s, got %s", expected, string(b))
    	}
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Feb 02 11:02:31 GMT 2024
    - 5.1K bytes
    - Viewed (0)
  5. cmd/storage-rest_test.go

    		}
    	}
    }
    
    func testStorageAPIRenameFile(t *testing.T, storage StorageAPI) {
    	err := storage.AppendFile(context.Background(), "foo", "myobject", []byte("foo"))
    	if err != nil {
    		t.Fatalf("unexpected error %v", err)
    	}
    
    	err = storage.AppendFile(context.Background(), "foo", "otherobject", []byte("foo"))
    	if err != nil {
    		t.Fatalf("unexpected error %v", err)
    	}
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jan 30 20:43:25 GMT 2024
    - 11.4K bytes
    - Viewed (0)
  6. cmd/erasure-encode_test.go

    	"context"
    	"crypto/rand"
    	"io"
    	"testing"
    
    	"github.com/dustin/go-humanize"
    )
    
    type badDisk struct{ StorageAPI }
    
    func (a badDisk) String() string {
    	return "bad-disk"
    }
    
    func (a badDisk) AppendFile(ctx context.Context, volume string, path string, buf []byte) error {
    	return errFaultyDisk
    }
    
    func (a badDisk) ReadFileStream(ctx context.Context, volume, path string, offset, length int64) (io.ReadCloser, error) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jan 30 20:43:25 GMT 2024
    - 11.9K bytes
    - Viewed (0)
Back to top