You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A better way in my view would be to ensure all the logic for restart policy gets moved to extensions.go and that a type of errors gets introduced (e.g ErrUnsupportedRestartPolicy). This makes the separation between presentation and validation by making it possible to assert the error occurred and moving the output handling to the UI.
The text was updated successfully, but these errors were encountered:
Restart policy is now split between 2 places:
https://github.com/appvia/kev/blob/5a1c05c568427024fb3ef76a9fc0a5d6bdd1e341/pkg/kev/config/extensions.go#L187
https://github.com/appvia/kev/blob/5a1c05c568427024fb3ef76a9fc0a5d6bdd1e341/pkg/kev/converter/kubernetes/project_service.go#L408
and some really inconvenient assertions (IMO)
https://github.com/appvia/kev/blob/5a1c05c568427024fb3ef76a9fc0a5d6bdd1e341/pkg/kev/converter/kubernetes/project_service_test.go#L1052
A better way in my view would be to ensure all the logic for restart policy gets moved to extensions.go and that a type of errors gets introduced (e.g ErrUnsupportedRestartPolicy). This makes the separation between presentation and validation by making it possible to assert the error occurred and moving the output handling to the UI.
The text was updated successfully, but these errors were encountered: