COMPMID-3378: CLScale failure

Avoid creating tests for unsupported cases

Change-Id: Ida0835af2f3d83c39544e930f8f5be3d4471fa38
Signed-off-by: Manuel Bottini <manuel.bottini@arm.com>
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/3022
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Sang-Hoon Park <sang-hoon.park@arm.com>
diff --git a/tests/validation/fixtures/ScaleFixture.h b/tests/validation/fixtures/ScaleFixture.h
index 8d851ce..e3846ed 100644
--- a/tests/validation/fixtures/ScaleFixture.h
+++ b/tests/validation/fixtures/ScaleFixture.h
@@ -70,6 +70,22 @@
         scale_x = ((shape[idx_width] * scale_x) > max_width) ? (max_width / shape[idx_width]) : scale_x;
         scale_y = ((shape[idx_height] * scale_y) > max_height) ? (max_height / shape[idx_height]) : scale_y;
 
+        const bool align_corners_a = policy == InterpolationPolicy::BILINEAR
+                                     && sampling_policy == SamplingPolicy::TOP_LEFT
+                                     && align_corners;
+
+        if(align_corners_a)
+        {
+            /* When align_corners = true is used for bilinear, both width and height
+             * of output should be > 1 to avoid overflow during computation otherwise
+             * it fails while checking argument values.
+             */
+            constexpr float min_width  = 2.f;
+            constexpr float min_height = 2.f;
+            scale_x                    = ((shape[idx_width] * scale_x) < min_width) ? (min_width / shape[idx_width]) : scale_x;
+            scale_y                    = ((shape[idx_height] * scale_y) < min_height) ? (min_height / shape[idx_height]) : scale_y;
+        }
+
         std::uniform_int_distribution<uint8_t> distribution_u8(0, 255);
         T                                      constant_border_value = static_cast<T>(distribution_u8(generator));