(t *testing.T)
| 65 | } |
| 66 | |
| 67 | func TestBuildSettingsAutoBackupRequiresPath(t *testing.T) { |
| 68 | t.Run("auto-backup without path", func(t *testing.T) { |
| 69 | f := &settingsFlags{autoBackup: true} |
| 70 | _, err := f.buildSettings("image:latest", "app.example.com") |
| 71 | assert.ErrorIs(t, err, docker.ErrAutoBackupWithoutPath) |
| 72 | }) |
| 73 | |
| 74 | t.Run("auto-backup with path", func(t *testing.T) { |
| 75 | f := &settingsFlags{autoBackup: true, backupPath: "/backups"} |
| 76 | _, err := f.buildSettings("image:latest", "app.example.com") |
| 77 | require.NoError(t, err) |
| 78 | }) |
| 79 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…