@ExtendWith({ RepositoryManagementTestExecutionListener.class,

              ArtifactManagementTestExecutionListener.class })
@Test
void shouldNotHandlePartialDownloadWithSingleRangeWhenOffsetGreaterThanLimit(
        @MavenRepository(repositoryId = REPOSITORY_RELEASES_3)
        Repository repository,
        @MavenTestArtifact(repositoryId = REPOSITORY_RELEASES_3,
                           id = "org.carlspring.strongbox:partial-multiple-not-satisfiable-validation",
                           versions = "1.0")
        Path artifactPath)
        throws IOException
{
    // Given
    RepositoryPath artifactRepositoryPath = (RepositoryPath) artifactPath.normalize();
    try(InputStream is = artifactResolutionService.getInputStream(artifactRepositoryPath))
    {
        String byteRanges = "49-0";
        HttpHeaders httpHeaders = getHttpHeaders(byteRanges);
        HttpServletResponse response = new MockHttpServletResponse();
        // When
        ArtifactControllerHelper.handlePartialDownload(is, httpHeaders, response);
        // Then
        assertThat(response.getStatus()).isEqualTo(HttpStatus.REQUESTED_RANGE_NOT_SATISFIABLE.value());
        assertThat(response.getHeader(HttpHeaders.CONTENT_RANGE)).startsWith("bytes */");
    }
}