package com.oguerreiro.resilient.service.mapper;

import static com.oguerreiro.resilient.domain.OutputDataAsserts.*;
import static com.oguerreiro.resilient.domain.OutputDataTestSamples.*;

import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

class OutputDataMapperTest {

    private OutputDataMapper outputDataMapper;

    @BeforeEach
    void setUp() {
        outputDataMapper = new OutputDataMapperImpl();
    }

    @Test
    void shouldConvertToDtoAndBack() {
        var expected = getOutputDataSample1();
        var actual = outputDataMapper.toEntity(outputDataMapper.toDto(expected));
        assertOutputDataAllPropertiesEquals(expected, actual);
    }
}
