ValidatePath checks if a valid migration chain exists between Start and End types.
(m *Migrator)
| 225 | |
| 226 | // ValidatePath checks if a valid migration chain exists between Start and End types. |
| 227 | func ValidatePath[Start Payload, End Payload](m *Migrator) error { |
| 228 | var start Start |
| 229 | var end End |
| 230 | |
| 231 | return m.validatePathInternal(start.Kind(), start.Version(), end.Kind(), end.Version()) |
| 232 | } |
| 233 | |
| 234 | func (m *Migrator) validatePathInternal(startKind, startVersion, endKind, endVersion string) error { |
| 235 | currKey := makeKey(startKind, startVersion) |
nothing calls this directly
no test coverage detected