diff options
| author | chrislu <chris.lu@gmail.com> | 2025-08-31 13:11:57 -0700 |
|---|---|---|
| committer | chrislu <chris.lu@gmail.com> | 2025-08-31 13:11:57 -0700 |
| commit | 705c965c5c8e67cf9fa10e34a26e3282227dd6e8 (patch) | |
| tree | 0930913b2c2ef6eed3b4179325da461e3e93e954 /test/fuse_integration/framework.go | |
| parent | a2378a29dcea338e598689344b139515db7814c4 (diff) | |
| download | seaweedfs-705c965c5c8e67cf9fa10e34a26e3282227dd6e8.tar.xz seaweedfs-705c965c5c8e67cf9fa10e34a26e3282227dd6e8.zip | |
fix
Diffstat (limited to 'test/fuse_integration/framework.go')
| -rw-r--r-- | test/fuse_integration/framework.go | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/fuse_integration/framework.go b/test/fuse_integration/framework.go index 32bcb97a9..c0ac39b77 100644 --- a/test/fuse_integration/framework.go +++ b/test/fuse_integration/framework.go @@ -106,6 +106,27 @@ func (f *FuseTestFramework) Setup(config *TestConfig) error { f.t.Logf("Warning: failed to cleanup test file: %v", err) } + // Verify this is actually a SeaweedFS mount by checking for SeaweedFS-specific behavior + // Create a test file and verify it appears in the filer + verifyFile := filepath.Join(f.mountPoint, ".seaweedfs_mount_verification") + if err := os.WriteFile(verifyFile, []byte("SeaweedFS mount verification"), 0644); err != nil { + return fmt.Errorf("mount point verification failed - cannot write: %v", err) + } + + // Read it back to ensure it's working + if data, err := os.ReadFile(verifyFile); err != nil { + return fmt.Errorf("mount point verification failed - cannot read: %v", err) + } else if string(data) != "SeaweedFS mount verification" { + return fmt.Errorf("mount point verification failed - data mismatch") + } + + // Clean up verification file + if err := os.Remove(verifyFile); err != nil { + f.t.Logf("Warning: failed to cleanup verification file: %v", err) + } + + f.t.Logf("✅ SeaweedFS mount point verified and working: %s", f.mountPoint) + f.isSetup = true return nil } |
