[#280] ir: Add container processor unit tests

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2023-04-26 12:05:33 +03:00 committed by Evgenii Stratonikov
parent 686f01bce5
commit 5010b35466
11 changed files with 409 additions and 51 deletions

View file

@ -120,7 +120,7 @@ func (cp *Processor) approvePutContainer(ctx *putContainerContext) {
// Process delete container operation from the user by checking container sanity
// and sending approve tx back to morph.
func (cp *Processor) processContainerDelete(e *containerEvent.Delete) {
func (cp *Processor) processContainerDelete(e containerEvent.Delete) {
if !cp.alphabetState.IsAlphabet() {
cp.log.Info(logs.ContainerNonAlphabetModeIgnoreContainerDelete)
return
@ -138,7 +138,7 @@ func (cp *Processor) processContainerDelete(e *containerEvent.Delete) {
cp.approveDeleteContainer(e)
}
func (cp *Processor) checkDeleteContainer(e *containerEvent.Delete) error {
func (cp *Processor) checkDeleteContainer(e containerEvent.Delete) error {
binCnr := e.ContainerID()
var idCnr cid.ID
@ -170,7 +170,7 @@ func (cp *Processor) checkDeleteContainer(e *containerEvent.Delete) error {
return nil
}
func (cp *Processor) approveDeleteContainer(e *containerEvent.Delete) {
func (cp *Processor) approveDeleteContainer(e containerEvent.Delete) {
var err error
prm := cntClient.DeletePrm{}