!38192 修复swiper组件镜像后失败TDD

Merge pull request !38192 from jiangzhijun8/master
This commit is contained in:
openharmony_ci 2024-07-19 08:13:33 +00:00 committed by Gitee
commit 999941f10d
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1915,7 +1915,7 @@ HWTEST_F(SwiperTestNg, FadeOverScroll001, TestSize.Level1)
offset = 0.0f; offset = 0.0f;
EXPECT_FALSE(pattern_->FadeOverScroll(offset)); EXPECT_FALSE(pattern_->FadeOverScroll(offset));
EXPECT_FALSE(pattern_->IsVisibleChildrenSizeLessThanSwiper()); EXPECT_FALSE(pattern_->IsVisibleChildrenSizeLessThanSwiper());
offset = -20.0f; offset = 10.0f;
EXPECT_TRUE(pattern_->FadeOverScroll(offset)); EXPECT_TRUE(pattern_->FadeOverScroll(offset));
} }
@ -1944,7 +1944,7 @@ HWTEST_F(SwiperTestNg, IsOutOfStart001, TestSize.Level1)
* @tc.steps: step2. call mirror func. * @tc.steps: step2. call mirror func.
*/ */
layoutProperty_->UpdateLayoutDirection(TextDirection::RTL); layoutProperty_->UpdateLayoutDirection(TextDirection::RTL);
offset = -10.0f; offset = 10.0f;
EXPECT_TRUE(pattern_->IsOutOfStart(offset)); EXPECT_TRUE(pattern_->IsOutOfStart(offset));
} }
@ -1993,7 +1993,7 @@ HWTEST_F(SwiperTestNg, IsOutOfBoundary001, TestSize.Level1)
* @tc.steps: step2. call mirror func. * @tc.steps: step2. call mirror func.
*/ */
layoutProperty_->UpdateLayoutDirection(TextDirection::RTL); layoutProperty_->UpdateLayoutDirection(TextDirection::RTL);
EXPECT_TRUE(pattern_->IsOutOfBoundary(10.0f)); EXPECT_TRUE(pattern_->IsOutOfBoundary(-10.0f));
} }
/** /**