mirror of
https://gitee.com/openharmony/arkui_ace_engine
synced 2025-02-25 14:05:40 +00:00
Revert "add waterFlow scrollToIndex test"
This reverts commit 10e7aed5b5197d8baab3fd78b78dccaadcaf767d. Change-Id: Ie4b3d02ef2270d3132c3a4442a8417a89293503b Signed-off-by: Tianer Zhou <zhoutianer@huawei.com>
This commit is contained in:
parent
b0f57a3c2d
commit
0aa725820b
@ -14,7 +14,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "water_flow_test_ng.h"
|
#include "water_flow_test_ng.h"
|
||||||
#include "core/components_ng/pattern/scrollable/scrollable_properties.h"
|
|
||||||
|
|
||||||
namespace OHOS::Ace::NG {
|
namespace OHOS::Ace::NG {
|
||||||
|
|
||||||
@ -542,27 +541,6 @@ HWTEST_F(WaterFlowScrollerTestNg, ScrollToIndex003, TestSize.Level1)
|
|||||||
EXPECT_FLOAT_EQ(pattern_->finalPosition_, 2100.f);
|
EXPECT_FLOAT_EQ(pattern_->finalPosition_, 2100.f);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @tc.name: ScrollToIndex004
|
|
||||||
* @tc.desc: Test ScrollToIndex while updating offset. Offset should be overriden
|
|
||||||
* @tc.type: FUNC
|
|
||||||
*/
|
|
||||||
HWTEST_F(WaterFlowScrollerTestNg, ScrollToIndex004, TestSize.Level1)
|
|
||||||
{
|
|
||||||
Create([](WaterFlowModelNG model) {
|
|
||||||
model.SetColumnsTemplate("1fr 1fr");
|
|
||||||
CreateRandomItem(100);
|
|
||||||
});
|
|
||||||
pattern_->ScrollToIndex(80, false, ScrollAlign::AUTO);
|
|
||||||
UpdateCurrentOffset(-20.0f);
|
|
||||||
EXPECT_EQ(GetChildRect(frameNode_, 80).Bottom(), WATERFLOW_HEIGHT);
|
|
||||||
|
|
||||||
pattern_->UpdateCurrentOffset(-20.0f, SCROLL_FROM_UPDATE);
|
|
||||||
pattern_->ScrollToIndex(20, false, ScrollAlign::AUTO);
|
|
||||||
FlushLayoutTask(frameNode_);
|
|
||||||
EXPECT_EQ(GetChildRect(frameNode_, 20).GetY(), 0.0f);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @tc.name: Focus001
|
* @tc.name: Focus001
|
||||||
* @tc.desc: Test WaterFlow scroll during focus change
|
* @tc.desc: Test WaterFlow scroll during focus change
|
||||||
|
Loading…
x
Reference in New Issue
Block a user