Closed nitishm closed 5 years ago
This change seems simple to me. Testing is more difficult. Since this project has no tests yet. Do you like a PR without tests? Otherwise, you have to wait a bit longer and you will get tests with the PR.
@enc go ahead with the PR. You can hold off on the testing for now. Just verify that the status updates cause the time stamps to be updated (on fail, canceled, completed).
BTW I have a feature open for unit tests that I have started some work on, but would appreciate some help with if you are interested. LMK.
@enc https://github.com/nitishm/vegeta-server/issues/40 is a pretty simple one, if you are interested.
I will have a look later. Cheers! @nitishm
Add the
CreatedAt
andUpdatedAt
fields tomodels.AttackDetails
, that get stored in the DB, to track the task submission time and the status update time. TheCreatedAt
is set indb.Add()
and theUpdatedAt
is updated every timedb.Update()
is invoked with theAttackDetails
.