Import "Fix percent absolute position and size calcuate different with web" behind experimental feature (#1028) (#1201)
Summary: Fixes https://github.com/facebook/yoga/issues/850 https://github.com/facebook/yoga/issues/850 describes a conformance issue where positioning of an absolute child using percentages is not calculated against the correct box size. This takes the fix for that in https://github.com/facebook/yoga/pull/1028, regenerates tests, and fixes tests so that the experimental feature can be enabled. Goal is to run this as an experiment internally to see if we can enable by default. Changelog: [Internal] Pull Request resolved: https://github.com/facebook/yoga/pull/1201 Reviewed By: yungsters Differential Revision: D42282358 Pulled By: NickGerleman fbshipit-source-id: 57c0dd9b0f1c47cb9335ff6e13d44b4646e5fa58
This commit is contained in:
committed by
Facebook GitHub Bot
parent
627255c0e4
commit
7e96b65790
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, absolute_layout_width_height_start_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -56,6 +58,8 @@ TEST(YogaTest, absolute_layout_width_height_start_top) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_width_height_end_bottom) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -99,6 +103,8 @@ TEST(YogaTest, absolute_layout_width_height_end_bottom) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_start_top_end_bottom) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -142,6 +148,8 @@ TEST(YogaTest, absolute_layout_start_top_end_bottom) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_width_height_start_top_end_bottom) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -187,6 +195,8 @@ TEST(YogaTest, absolute_layout_width_height_start_top_end_bottom) {
|
||||
|
||||
TEST(YogaTest, do_not_clamp_height_of_absolute_node_to_height_of_its_overflow_hidden_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -245,6 +255,8 @@ TEST(YogaTest, do_not_clamp_height_of_absolute_node_to_height_of_its_overflow_hi
|
||||
|
||||
TEST(YogaTest, absolute_layout_within_border) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetMargin(root, YGEdgeLeft, 10);
|
||||
@@ -362,6 +374,8 @@ TEST(YogaTest, absolute_layout_within_border) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -406,6 +420,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_center) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyFlexEnd);
|
||||
@@ -450,6 +466,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_flex_end) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_justify_content_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -493,6 +511,8 @@ TEST(YogaTest, absolute_layout_justify_content_center) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -536,6 +556,8 @@ TEST(YogaTest, absolute_layout_align_items_center) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_center_on_child_only) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexGrow(root, 1);
|
||||
@@ -579,6 +601,8 @@ TEST(YogaTest, absolute_layout_align_items_center_on_child_only) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_top_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -624,6 +648,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_top_po
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_bottom_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -669,6 +695,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_bottom
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_left_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -714,6 +742,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_left_p
|
||||
|
||||
TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_right_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -759,6 +789,8 @@ TEST(YogaTest, absolute_layout_align_items_and_justify_content_center_and_right_
|
||||
|
||||
TEST(YogaTest, position_root_with_rtl_should_position_withoutdirection) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPosition(root, YGEdgeLeft, 72);
|
||||
@@ -785,6 +817,8 @@ TEST(YogaTest, position_root_with_rtl_should_position_withoutdirection) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_percentage_bottom_based_on_parent_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -861,6 +895,8 @@ TEST(YogaTest, absolute_layout_percentage_bottom_based_on_parent_height) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_in_wrap_reverse_column_container) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexWrap(root, YGWrapWrapReverse);
|
||||
@@ -903,6 +939,8 @@ TEST(YogaTest, absolute_layout_in_wrap_reverse_column_container) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_in_wrap_reverse_row_container) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -946,6 +984,8 @@ TEST(YogaTest, absolute_layout_in_wrap_reverse_row_container) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_in_wrap_reverse_column_container_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexWrap(root, YGWrapWrapReverse);
|
||||
@@ -989,6 +1029,8 @@ TEST(YogaTest, absolute_layout_in_wrap_reverse_column_container_flex_end) {
|
||||
|
||||
TEST(YogaTest, absolute_layout_in_wrap_reverse_row_container_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1030,3 +1072,153 @@ TEST(YogaTest, absolute_layout_in_wrap_reverse_row_container_flex_end) {
|
||||
|
||||
YGConfigFree(config);
|
||||
}
|
||||
|
||||
TEST(YogaTest, percent_absolute_position_infinite_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 300);
|
||||
|
||||
const YGNodeRef root_child0 = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root_child0, 300);
|
||||
YGNodeInsertChild(root, root_child0, 0);
|
||||
|
||||
const YGNodeRef root_child1 = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPositionType(root_child1, YGPositionTypeAbsolute);
|
||||
YGNodeStyleSetPositionPercent(root_child1, YGEdgeLeft, 20);
|
||||
YGNodeStyleSetPositionPercent(root_child1, YGEdgeTop, 20);
|
||||
YGNodeStyleSetWidthPercent(root_child1, 20);
|
||||
YGNodeStyleSetHeightPercent(root_child1, 20);
|
||||
YGNodeInsertChild(root, root_child1, 1);
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(300, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(300, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
ASSERT_FLOAT_EQ(60, YGNodeLayoutGetLeft(root_child1));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root_child1));
|
||||
ASSERT_FLOAT_EQ(60, YGNodeLayoutGetWidth(root_child1));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root_child1));
|
||||
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionRTL);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(300, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(300, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
ASSERT_FLOAT_EQ(60, YGNodeLayoutGetLeft(root_child1));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root_child1));
|
||||
ASSERT_FLOAT_EQ(60, YGNodeLayoutGetWidth(root_child1));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetHeight(root_child1));
|
||||
|
||||
YGNodeFreeRecursive(root);
|
||||
|
||||
YGConfigFree(config);
|
||||
}
|
||||
|
||||
TEST(YogaTest, absolute_layout_percentage_height_based_on_padded_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPadding(root, YGEdgeTop, 10);
|
||||
YGNodeStyleSetBorder(root, YGEdgeTop, 10);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
YGNodeStyleSetHeight(root, 100);
|
||||
|
||||
const YGNodeRef root_child0 = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPositionType(root_child0, YGPositionTypeAbsolute);
|
||||
YGNodeStyleSetWidth(root_child0, 100);
|
||||
YGNodeStyleSetHeightPercent(root_child0, 50);
|
||||
YGNodeInsertChild(root, root_child0, 0);
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(10, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(50, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionRTL);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(10, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(50, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
YGNodeFreeRecursive(root);
|
||||
|
||||
YGConfigFree(config);
|
||||
}
|
||||
|
||||
TEST(YogaTest, absolute_layout_percentage_height_based_on_padded_parent_and_align_items_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
YGNodeStyleSetPadding(root, YGEdgeTop, 20);
|
||||
YGNodeStyleSetPadding(root, YGEdgeBottom, 20);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
YGNodeStyleSetHeight(root, 100);
|
||||
|
||||
const YGNodeRef root_child0 = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPositionType(root_child0, YGPositionTypeAbsolute);
|
||||
YGNodeStyleSetWidth(root_child0, 100);
|
||||
YGNodeStyleSetHeightPercent(root_child0, 50);
|
||||
YGNodeInsertChild(root, root_child0, 0);
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(25, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(50, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionRTL);
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root));
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetTop(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetHeight(root));
|
||||
|
||||
ASSERT_FLOAT_EQ(0, YGNodeLayoutGetLeft(root_child0));
|
||||
ASSERT_FLOAT_EQ(25, YGNodeLayoutGetTop(root_child0));
|
||||
ASSERT_FLOAT_EQ(100, YGNodeLayoutGetWidth(root_child0));
|
||||
ASSERT_FLOAT_EQ(50, YGNodeLayoutGetHeight(root_child0));
|
||||
|
||||
YGNodeFreeRecursive(root);
|
||||
|
||||
YGConfigFree(config);
|
||||
}
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, align_content_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -115,6 +117,8 @@ TEST(YogaTest, align_content_flex_start) {
|
||||
|
||||
TEST(YogaTest, align_content_flex_start_without_height_on_children) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexWrap(root, YGWrapWrap);
|
||||
@@ -213,6 +217,8 @@ TEST(YogaTest, align_content_flex_start_without_height_on_children) {
|
||||
|
||||
TEST(YogaTest, align_content_flex_start_with_flex) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexWrap(root, YGWrapWrap);
|
||||
@@ -317,6 +323,8 @@ TEST(YogaTest, align_content_flex_start_with_flex) {
|
||||
|
||||
TEST(YogaTest, align_content_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignFlexEnd);
|
||||
@@ -419,6 +427,8 @@ TEST(YogaTest, align_content_flex_end) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
@@ -516,6 +526,8 @@ TEST(YogaTest, align_content_stretch) {
|
||||
|
||||
TEST(YogaTest, align_content_spacebetween) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -619,6 +631,8 @@ TEST(YogaTest, align_content_spacebetween) {
|
||||
|
||||
TEST(YogaTest, align_content_spacearound) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -722,6 +736,8 @@ TEST(YogaTest, align_content_spacearound) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -820,6 +836,8 @@ TEST(YogaTest, align_content_stretch_row) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_children) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -934,6 +952,8 @@ TEST(YogaTest, align_content_stretch_row_with_children) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_flex) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1038,6 +1058,8 @@ TEST(YogaTest, align_content_stretch_row_with_flex) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_flex_no_shrink) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1141,6 +1163,8 @@ TEST(YogaTest, align_content_stretch_row_with_flex_no_shrink) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1247,6 +1271,8 @@ TEST(YogaTest, align_content_stretch_row_with_margin) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_padding) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1353,6 +1379,8 @@ TEST(YogaTest, align_content_stretch_row_with_padding) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_single_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1409,6 +1437,8 @@ TEST(YogaTest, align_content_stretch_row_with_single_row) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_fixed_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1508,6 +1538,8 @@ TEST(YogaTest, align_content_stretch_row_with_fixed_height) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1607,6 +1639,8 @@ TEST(YogaTest, align_content_stretch_row_with_max_height) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_row_with_min_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1706,6 +1740,8 @@ TEST(YogaTest, align_content_stretch_row_with_min_height) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
@@ -1822,6 +1858,8 @@ TEST(YogaTest, align_content_stretch_column) {
|
||||
|
||||
TEST(YogaTest, align_content_stretch_is_not_overriding_align_items) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, align_items_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -52,6 +54,8 @@ TEST(YogaTest, align_items_stretch) {
|
||||
|
||||
TEST(YogaTest, align_items_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -93,6 +97,8 @@ TEST(YogaTest, align_items_center) {
|
||||
|
||||
TEST(YogaTest, align_items_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexStart);
|
||||
@@ -134,6 +140,8 @@ TEST(YogaTest, align_items_flex_start) {
|
||||
|
||||
TEST(YogaTest, align_items_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexEnd);
|
||||
@@ -175,6 +183,8 @@ TEST(YogaTest, align_items_flex_end) {
|
||||
|
||||
TEST(YogaTest, align_baseline) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -232,6 +242,8 @@ TEST(YogaTest, align_baseline) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -304,6 +316,8 @@ TEST(YogaTest, align_baseline_child) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_multiline) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -423,6 +437,8 @@ TEST(YogaTest, align_baseline_child_multiline) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_multiline_override) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -544,6 +560,8 @@ TEST(YogaTest, align_baseline_child_multiline_override) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_multiline_no_override_on_secondline) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -664,6 +682,8 @@ TEST(YogaTest, align_baseline_child_multiline_no_override_on_secondline) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -737,6 +757,8 @@ TEST(YogaTest, align_baseline_child_top) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_top2) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -810,6 +832,8 @@ TEST(YogaTest, align_baseline_child_top2) {
|
||||
|
||||
TEST(YogaTest, align_baseline_double_nested_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -897,6 +921,8 @@ TEST(YogaTest, align_baseline_double_nested_child) {
|
||||
|
||||
TEST(YogaTest, align_baseline_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignBaseline);
|
||||
@@ -953,6 +979,8 @@ TEST(YogaTest, align_baseline_column) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1033,6 +1061,8 @@ TEST(YogaTest, align_baseline_child_margin) {
|
||||
|
||||
TEST(YogaTest, align_baseline_child_padding) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1113,6 +1143,8 @@ TEST(YogaTest, align_baseline_child_padding) {
|
||||
|
||||
TEST(YogaTest, align_baseline_multiline) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1231,6 +1263,8 @@ TEST(YogaTest, align_baseline_multiline) {
|
||||
|
||||
TEST(YogaTest, align_baseline_multiline_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignBaseline);
|
||||
@@ -1348,6 +1382,8 @@ TEST(YogaTest, align_baseline_multiline_column) {
|
||||
|
||||
TEST(YogaTest, align_baseline_multiline_column2) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignBaseline);
|
||||
@@ -1465,6 +1501,8 @@ TEST(YogaTest, align_baseline_multiline_column2) {
|
||||
|
||||
TEST(YogaTest, align_baseline_multiline_row_and_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1583,6 +1621,8 @@ TEST(YogaTest, align_baseline_multiline_row_and_column) {
|
||||
|
||||
TEST(YogaTest, align_items_center_child_with_margin_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1641,6 +1681,8 @@ TEST(YogaTest, align_items_center_child_with_margin_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, align_items_flex_end_child_with_margin_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1699,6 +1741,8 @@ TEST(YogaTest, align_items_flex_end_child_with_margin_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, align_items_center_child_without_margin_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1755,6 +1799,8 @@ TEST(YogaTest, align_items_center_child_without_margin_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, align_items_flex_end_child_without_margin_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1811,6 +1857,8 @@ TEST(YogaTest, align_items_flex_end_child_without_margin_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, align_center_should_size_based_on_content) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1883,6 +1931,8 @@ TEST(YogaTest, align_center_should_size_based_on_content) {
|
||||
|
||||
TEST(YogaTest, align_stretch_should_size_based_on_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetMargin(root, YGEdgeTop, 20);
|
||||
@@ -1954,6 +2004,8 @@ TEST(YogaTest, align_stretch_should_size_based_on_parent) {
|
||||
|
||||
TEST(YogaTest, align_flex_start_with_shrinking_children) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 500);
|
||||
@@ -2023,6 +2075,8 @@ TEST(YogaTest, align_flex_start_with_shrinking_children) {
|
||||
|
||||
TEST(YogaTest, align_flex_start_with_stretching_children) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 500);
|
||||
@@ -2091,6 +2145,8 @@ TEST(YogaTest, align_flex_start_with_stretching_children) {
|
||||
|
||||
TEST(YogaTest, align_flex_start_with_shrinking_children_with_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 500);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, align_self_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -54,6 +56,8 @@ TEST(YogaTest, align_self_center) {
|
||||
|
||||
TEST(YogaTest, align_self_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -95,6 +99,8 @@ TEST(YogaTest, align_self_flex_end) {
|
||||
|
||||
TEST(YogaTest, align_self_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -136,6 +142,8 @@ TEST(YogaTest, align_self_flex_start) {
|
||||
|
||||
TEST(YogaTest, align_self_flex_end_override_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexStart);
|
||||
@@ -178,6 +186,8 @@ TEST(YogaTest, align_self_flex_end_override_flex_start) {
|
||||
|
||||
TEST(YogaTest, align_self_baseline) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, android_news_feed) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, border_no_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetBorder(root, YGEdgeLeft, 10);
|
||||
@@ -40,6 +42,8 @@ TEST(YogaTest, border_no_size) {
|
||||
|
||||
TEST(YogaTest, border_container_match_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetBorder(root, YGEdgeLeft, 10);
|
||||
@@ -82,6 +86,8 @@ TEST(YogaTest, border_container_match_child) {
|
||||
|
||||
TEST(YogaTest, border_flex_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetBorder(root, YGEdgeLeft, 10);
|
||||
@@ -126,6 +132,8 @@ TEST(YogaTest, border_flex_child) {
|
||||
|
||||
TEST(YogaTest, border_stretch_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetBorder(root, YGEdgeLeft, 10);
|
||||
@@ -169,6 +177,8 @@ TEST(YogaTest, border_stretch_child) {
|
||||
|
||||
TEST(YogaTest, border_center_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, wrap_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
|
||||
@@ -51,6 +53,8 @@ TEST(YogaTest, wrap_child) {
|
||||
|
||||
TEST(YogaTest, wrap_grandchild) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, display_none) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -68,6 +70,8 @@ TEST(YogaTest, display_none) {
|
||||
|
||||
TEST(YogaTest, display_none_fixed_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -124,6 +128,8 @@ TEST(YogaTest, display_none_fixed_size) {
|
||||
|
||||
TEST(YogaTest, display_none_with_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -184,6 +190,8 @@ TEST(YogaTest, display_none_with_margin) {
|
||||
|
||||
TEST(YogaTest, display_none_with_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -276,6 +284,8 @@ TEST(YogaTest, display_none_with_child) {
|
||||
|
||||
TEST(YogaTest, display_none_with_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -332,6 +342,8 @@ TEST(YogaTest, display_none_with_position) {
|
||||
|
||||
TEST(YogaTest, display_none_with_position_absolute) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, flex_direction_column_no_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -79,6 +81,8 @@ TEST(YogaTest, flex_direction_column_no_height) {
|
||||
|
||||
TEST(YogaTest, flex_direction_row_no_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -146,6 +150,8 @@ TEST(YogaTest, flex_direction_row_no_width) {
|
||||
|
||||
TEST(YogaTest, flex_direction_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -213,6 +219,8 @@ TEST(YogaTest, flex_direction_column) {
|
||||
|
||||
TEST(YogaTest, flex_direction_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -281,6 +289,8 @@ TEST(YogaTest, flex_direction_row) {
|
||||
|
||||
TEST(YogaTest, flex_direction_column_reverse) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionColumnReverse);
|
||||
@@ -349,6 +359,8 @@ TEST(YogaTest, flex_direction_column_reverse) {
|
||||
|
||||
TEST(YogaTest, flex_direction_row_reverse) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRowReverse);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, flex_basis_flex_grow_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -67,6 +69,8 @@ TEST(YogaTest, flex_basis_flex_grow_column) {
|
||||
|
||||
TEST(YogaTest, flex_shrink_flex_grow_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -125,6 +129,8 @@ TEST(YogaTest, flex_shrink_flex_grow_row) {
|
||||
|
||||
TEST(YogaTest, flex_shrink_flex_grow_child_flex_shrink_other_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -184,6 +190,8 @@ TEST(YogaTest, flex_shrink_flex_grow_child_flex_shrink_other_child) {
|
||||
|
||||
TEST(YogaTest, flex_basis_flex_grow_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -239,6 +247,8 @@ TEST(YogaTest, flex_basis_flex_grow_row) {
|
||||
|
||||
TEST(YogaTest, flex_basis_flex_shrink_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -293,6 +303,8 @@ TEST(YogaTest, flex_basis_flex_shrink_column) {
|
||||
|
||||
TEST(YogaTest, flex_basis_flex_shrink_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -348,6 +360,8 @@ TEST(YogaTest, flex_basis_flex_shrink_row) {
|
||||
|
||||
TEST(YogaTest, flex_shrink_to_zero) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetHeight(root, 75);
|
||||
@@ -418,6 +432,8 @@ TEST(YogaTest, flex_shrink_to_zero) {
|
||||
|
||||
TEST(YogaTest, flex_basis_overrides_main_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -489,6 +505,8 @@ TEST(YogaTest, flex_basis_overrides_main_size) {
|
||||
|
||||
TEST(YogaTest, flex_grow_shrink_at_most) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -542,6 +560,8 @@ TEST(YogaTest, flex_grow_shrink_at_most) {
|
||||
|
||||
TEST(YogaTest, flex_grow_less_than_factor_one) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, wrap_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexWrap(root, YGWrapWrap);
|
||||
@@ -98,6 +100,8 @@ TEST(YogaTest, wrap_column) {
|
||||
|
||||
TEST(YogaTest, wrap_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -184,6 +188,8 @@ TEST(YogaTest, wrap_row) {
|
||||
|
||||
TEST(YogaTest, wrap_row_align_items_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -271,6 +277,8 @@ TEST(YogaTest, wrap_row_align_items_flex_end) {
|
||||
|
||||
TEST(YogaTest, wrap_row_align_items_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -358,6 +366,8 @@ TEST(YogaTest, wrap_row_align_items_center) {
|
||||
|
||||
TEST(YogaTest, flex_wrap_children_with_min_main_overriding_flex_basis) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -416,6 +426,8 @@ TEST(YogaTest, flex_wrap_children_with_min_main_overriding_flex_basis) {
|
||||
|
||||
TEST(YogaTest, flex_wrap_wrap_to_child_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
|
||||
@@ -499,6 +511,8 @@ TEST(YogaTest, flex_wrap_wrap_to_child_height) {
|
||||
|
||||
TEST(YogaTest, flex_wrap_align_stretch_fits_one_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -554,6 +568,8 @@ TEST(YogaTest, flex_wrap_align_stretch_fits_one_row) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_row_align_content_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -655,6 +671,8 @@ TEST(YogaTest, wrap_reverse_row_align_content_flex_start) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_row_align_content_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -757,6 +775,8 @@ TEST(YogaTest, wrap_reverse_row_align_content_center) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_row_single_line_different_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -858,6 +878,8 @@ TEST(YogaTest, wrap_reverse_row_single_line_different_size) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_row_align_content_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -960,6 +982,8 @@ TEST(YogaTest, wrap_reverse_row_align_content_stretch) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_row_align_content_space_around) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1062,6 +1086,8 @@ TEST(YogaTest, wrap_reverse_row_align_content_space_around) {
|
||||
|
||||
TEST(YogaTest, wrap_reverse_column_fixed_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1164,6 +1190,8 @@ TEST(YogaTest, wrap_reverse_column_fixed_size) {
|
||||
|
||||
TEST(YogaTest, wrapped_row_within_align_items_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1235,6 +1263,8 @@ TEST(YogaTest, wrapped_row_within_align_items_center) {
|
||||
|
||||
TEST(YogaTest, wrapped_row_within_align_items_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexStart);
|
||||
@@ -1306,6 +1336,8 @@ TEST(YogaTest, wrapped_row_within_align_items_flex_start) {
|
||||
|
||||
TEST(YogaTest, wrapped_row_within_align_items_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexEnd);
|
||||
@@ -1377,6 +1409,8 @@ TEST(YogaTest, wrapped_row_within_align_items_flex_end) {
|
||||
|
||||
TEST(YogaTest, wrapped_column_max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1456,6 +1490,8 @@ TEST(YogaTest, wrapped_column_max_height) {
|
||||
|
||||
TEST(YogaTest, wrapped_column_max_height_flex) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1541,6 +1577,8 @@ TEST(YogaTest, wrapped_column_max_height_flex) {
|
||||
|
||||
TEST(YogaTest, wrap_nodes_with_content_sizing_overflowing_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 500);
|
||||
@@ -1639,6 +1677,8 @@ TEST(YogaTest, wrap_nodes_with_content_sizing_overflowing_margin) {
|
||||
|
||||
TEST(YogaTest, wrap_nodes_with_content_sizing_margin_cross) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 500);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, column_gap_flexible) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -89,6 +91,8 @@ TEST(YogaTest, column_gap_flexible) {
|
||||
|
||||
TEST(YogaTest, column_gap_inflexible) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -158,6 +162,8 @@ TEST(YogaTest, column_gap_inflexible) {
|
||||
|
||||
TEST(YogaTest, column_gap_mixed_flexible) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -229,6 +235,8 @@ TEST(YogaTest, column_gap_mixed_flexible) {
|
||||
|
||||
TEST(YogaTest, column_gap_child_margins) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -310,6 +318,8 @@ TEST(YogaTest, column_gap_child_margins) {
|
||||
|
||||
TEST(YogaTest, column_row_gap_wrapping) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -473,6 +483,8 @@ TEST(YogaTest, column_row_gap_wrapping) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -542,6 +554,8 @@ TEST(YogaTest, column_gap_justify_flex_start) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -612,6 +626,8 @@ TEST(YogaTest, column_gap_justify_center) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -682,6 +698,8 @@ TEST(YogaTest, column_gap_justify_flex_end) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_space_between) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -752,6 +770,8 @@ TEST(YogaTest, column_gap_justify_space_between) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_space_around) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -822,6 +842,8 @@ TEST(YogaTest, column_gap_justify_space_around) {
|
||||
|
||||
TEST(YogaTest, column_gap_justify_space_evenly) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -892,6 +914,8 @@ TEST(YogaTest, column_gap_justify_space_evenly) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1011,6 +1035,8 @@ TEST(YogaTest, column_gap_wrap_align_flex_start) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1131,6 +1157,8 @@ TEST(YogaTest, column_gap_wrap_align_center) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1251,6 +1279,8 @@ TEST(YogaTest, column_gap_wrap_align_flex_end) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_space_between) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1371,6 +1401,8 @@ TEST(YogaTest, column_gap_wrap_align_space_between) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_space_around) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1491,6 +1523,8 @@ TEST(YogaTest, column_gap_wrap_align_space_around) {
|
||||
|
||||
TEST(YogaTest, column_gap_wrap_align_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1595,6 +1629,8 @@ TEST(YogaTest, column_gap_wrap_align_stretch) {
|
||||
|
||||
TEST(YogaTest, column_gap_determines_parent_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1663,6 +1699,8 @@ TEST(YogaTest, column_gap_determines_parent_width) {
|
||||
|
||||
TEST(YogaTest, row_gap_align_items_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1777,6 +1815,8 @@ TEST(YogaTest, row_gap_align_items_stretch) {
|
||||
|
||||
TEST(YogaTest, row_gap_align_items_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1891,6 +1931,8 @@ TEST(YogaTest, row_gap_align_items_end) {
|
||||
|
||||
TEST(YogaTest, row_gap_column_child_margins) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -1971,6 +2013,8 @@ TEST(YogaTest, row_gap_column_child_margins) {
|
||||
|
||||
TEST(YogaTest, row_gap_row_wrap_child_margins) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -2047,6 +2091,8 @@ TEST(YogaTest, row_gap_row_wrap_child_margins) {
|
||||
|
||||
TEST(YogaTest, row_gap_determines_parent_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, justify_content_row_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -81,6 +83,8 @@ TEST(YogaTest, justify_content_row_flex_start) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -150,6 +154,8 @@ TEST(YogaTest, justify_content_row_flex_end) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -219,6 +225,8 @@ TEST(YogaTest, justify_content_row_center) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_space_between) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -288,6 +296,8 @@ TEST(YogaTest, justify_content_row_space_between) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_space_around) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -357,6 +367,8 @@ TEST(YogaTest, justify_content_row_space_around) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_flex_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 102);
|
||||
@@ -424,6 +436,8 @@ TEST(YogaTest, justify_content_column_flex_start) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_flex_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyFlexEnd);
|
||||
@@ -492,6 +506,8 @@ TEST(YogaTest, justify_content_column_flex_end) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -560,6 +576,8 @@ TEST(YogaTest, justify_content_column_center) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_space_between) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifySpaceBetween);
|
||||
@@ -628,6 +646,8 @@ TEST(YogaTest, justify_content_column_space_between) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_space_around) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifySpaceAround);
|
||||
@@ -696,6 +716,8 @@ TEST(YogaTest, justify_content_column_space_around) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_min_width_and_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -738,6 +760,8 @@ TEST(YogaTest, justify_content_row_min_width_and_margin) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_max_width_and_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -781,6 +805,8 @@ TEST(YogaTest, justify_content_row_max_width_and_margin) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_min_height_and_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -822,6 +848,8 @@ TEST(YogaTest, justify_content_column_min_height_and_margin) {
|
||||
|
||||
TEST(YogaTest, justify_content_colunn_max_height_and_margin) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -864,6 +892,8 @@ TEST(YogaTest, justify_content_colunn_max_height_and_margin) {
|
||||
|
||||
TEST(YogaTest, justify_content_column_space_evenly) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifySpaceEvenly);
|
||||
@@ -932,6 +962,8 @@ TEST(YogaTest, justify_content_column_space_evenly) {
|
||||
|
||||
TEST(YogaTest, justify_content_row_space_evenly) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1001,6 +1033,8 @@ TEST(YogaTest, justify_content_row_space_evenly) {
|
||||
|
||||
TEST(YogaTest, justify_content_min_width_with_padding_child_width_greater_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
@@ -1078,6 +1112,8 @@ TEST(YogaTest, justify_content_min_width_with_padding_child_width_greater_than_p
|
||||
|
||||
TEST(YogaTest, justify_content_min_width_with_padding_child_width_lower_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignContent(root, YGAlignStretch);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, margin_start) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -54,6 +56,8 @@ TEST(YogaTest, margin_start) {
|
||||
|
||||
TEST(YogaTest, margin_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -94,6 +98,8 @@ TEST(YogaTest, margin_top) {
|
||||
|
||||
TEST(YogaTest, margin_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -136,6 +142,8 @@ TEST(YogaTest, margin_end) {
|
||||
|
||||
TEST(YogaTest, margin_bottom) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyFlexEnd);
|
||||
@@ -177,6 +185,8 @@ TEST(YogaTest, margin_bottom) {
|
||||
|
||||
TEST(YogaTest, margin_and_flex_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -219,6 +229,8 @@ TEST(YogaTest, margin_and_flex_row) {
|
||||
|
||||
TEST(YogaTest, margin_and_flex_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -260,6 +272,8 @@ TEST(YogaTest, margin_and_flex_column) {
|
||||
|
||||
TEST(YogaTest, margin_and_stretch_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -302,6 +316,8 @@ TEST(YogaTest, margin_and_stretch_row) {
|
||||
|
||||
TEST(YogaTest, margin_and_stretch_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -343,6 +359,8 @@ TEST(YogaTest, margin_and_stretch_column) {
|
||||
|
||||
TEST(YogaTest, margin_with_sibling_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -398,6 +416,8 @@ TEST(YogaTest, margin_with_sibling_row) {
|
||||
|
||||
TEST(YogaTest, margin_with_sibling_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -452,6 +472,8 @@ TEST(YogaTest, margin_with_sibling_column) {
|
||||
|
||||
TEST(YogaTest, margin_auto_bottom) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -509,6 +531,8 @@ TEST(YogaTest, margin_auto_bottom) {
|
||||
|
||||
TEST(YogaTest, margin_auto_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -566,6 +590,8 @@ TEST(YogaTest, margin_auto_top) {
|
||||
|
||||
TEST(YogaTest, margin_auto_bottom_and_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -624,6 +650,8 @@ TEST(YogaTest, margin_auto_bottom_and_top) {
|
||||
|
||||
TEST(YogaTest, margin_auto_bottom_and_top_justify_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -682,6 +710,8 @@ TEST(YogaTest, margin_auto_bottom_and_top_justify_center) {
|
||||
|
||||
TEST(YogaTest, margin_auto_mutiple_children_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -755,6 +785,8 @@ TEST(YogaTest, margin_auto_mutiple_children_column) {
|
||||
|
||||
TEST(YogaTest, margin_auto_mutiple_children_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -829,6 +861,8 @@ TEST(YogaTest, margin_auto_mutiple_children_row) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_and_right_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -888,6 +922,8 @@ TEST(YogaTest, margin_auto_left_and_right_column) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_and_right) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -945,6 +981,8 @@ TEST(YogaTest, margin_auto_left_and_right) {
|
||||
|
||||
TEST(YogaTest, margin_auto_start_and_end_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1004,6 +1042,8 @@ TEST(YogaTest, margin_auto_start_and_end_column) {
|
||||
|
||||
TEST(YogaTest, margin_auto_start_and_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -1061,6 +1101,8 @@ TEST(YogaTest, margin_auto_start_and_end) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_and_right_column_and_center) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1119,6 +1161,8 @@ TEST(YogaTest, margin_auto_left_and_right_column_and_center) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1176,6 +1220,8 @@ TEST(YogaTest, margin_auto_left) {
|
||||
|
||||
TEST(YogaTest, margin_auto_right) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1233,6 +1279,8 @@ TEST(YogaTest, margin_auto_right) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_and_right_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1291,6 +1339,8 @@ TEST(YogaTest, margin_auto_left_and_right_stretch) {
|
||||
|
||||
TEST(YogaTest, margin_auto_top_and_bottom_stretch) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -1348,6 +1398,8 @@ TEST(YogaTest, margin_auto_top_and_bottom_stretch) {
|
||||
|
||||
TEST(YogaTest, margin_should_not_be_part_of_max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 250);
|
||||
@@ -1390,6 +1442,8 @@ TEST(YogaTest, margin_should_not_be_part_of_max_height) {
|
||||
|
||||
TEST(YogaTest, margin_should_not_be_part_of_max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 250);
|
||||
@@ -1432,6 +1486,8 @@ TEST(YogaTest, margin_should_not_be_part_of_max_width) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_right_child_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1475,6 +1531,8 @@ TEST(YogaTest, margin_auto_left_right_child_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_child_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1517,6 +1575,8 @@ TEST(YogaTest, margin_auto_left_child_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, margin_fix_left_auto_right_child_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1560,6 +1620,8 @@ TEST(YogaTest, margin_fix_left_auto_right_child_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_fix_right_child_bigger_than_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1603,6 +1665,8 @@ TEST(YogaTest, margin_auto_left_fix_right_child_bigger_than_parent) {
|
||||
|
||||
TEST(YogaTest, margin_auto_top_stretching_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -1661,6 +1725,8 @@ TEST(YogaTest, margin_auto_top_stretching_child) {
|
||||
|
||||
TEST(YogaTest, margin_auto_left_stretching_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -53,6 +55,8 @@ TEST(YogaTest, max_width) {
|
||||
|
||||
TEST(YogaTest, max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -94,6 +98,8 @@ TEST(YogaTest, max_height) {
|
||||
|
||||
TEST(YogaTest, justify_content_min_max) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -136,6 +142,8 @@ TEST(YogaTest, justify_content_min_max) {
|
||||
|
||||
TEST(YogaTest, align_items_min_max) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignCenter);
|
||||
@@ -178,6 +186,8 @@ TEST(YogaTest, align_items_min_max) {
|
||||
|
||||
TEST(YogaTest, justify_content_overflow_min_max) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -249,6 +259,8 @@ TEST(YogaTest, justify_content_overflow_min_max) {
|
||||
|
||||
TEST(YogaTest, flex_grow_to_min) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -304,6 +316,8 @@ TEST(YogaTest, flex_grow_to_min) {
|
||||
|
||||
TEST(YogaTest, flex_grow_in_at_most_container) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -360,6 +374,8 @@ TEST(YogaTest, flex_grow_in_at_most_container) {
|
||||
|
||||
TEST(YogaTest, flex_grow_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -400,6 +416,8 @@ TEST(YogaTest, flex_grow_child) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_min_max_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetMinHeight(root, 100);
|
||||
@@ -453,6 +471,8 @@ TEST(YogaTest, flex_grow_within_constrained_min_max_column) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -508,6 +528,8 @@ TEST(YogaTest, flex_grow_within_max_width) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -563,6 +585,8 @@ TEST(YogaTest, flex_grow_within_constrained_max_width) {
|
||||
|
||||
TEST(YogaTest, flex_root_ignored) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexGrow(root, 1);
|
||||
@@ -619,6 +643,8 @@ TEST(YogaTest, flex_root_ignored) {
|
||||
|
||||
TEST(YogaTest, flex_grow_root_minimized) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -690,6 +716,8 @@ TEST(YogaTest, flex_grow_root_minimized) {
|
||||
|
||||
TEST(YogaTest, flex_grow_height_maximized) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -760,6 +788,8 @@ TEST(YogaTest, flex_grow_height_maximized) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_min_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -814,6 +844,8 @@ TEST(YogaTest, flex_grow_within_constrained_min_row) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_min_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetMinHeight(root, 100);
|
||||
@@ -866,6 +898,8 @@ TEST(YogaTest, flex_grow_within_constrained_min_column) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_max_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -935,6 +969,8 @@ TEST(YogaTest, flex_grow_within_constrained_max_row) {
|
||||
|
||||
TEST(YogaTest, flex_grow_within_constrained_max_column) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -989,6 +1025,8 @@ TEST(YogaTest, flex_grow_within_constrained_max_column) {
|
||||
|
||||
TEST(YogaTest, child_min_max_width_flexing) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -1047,6 +1085,8 @@ TEST(YogaTest, child_min_max_width_flexing) {
|
||||
|
||||
TEST(YogaTest, min_width_overrides_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 50);
|
||||
@@ -1072,6 +1112,8 @@ TEST(YogaTest, min_width_overrides_width) {
|
||||
|
||||
TEST(YogaTest, max_width_overrides_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -1097,6 +1139,8 @@ TEST(YogaTest, max_width_overrides_width) {
|
||||
|
||||
TEST(YogaTest, min_height_overrides_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetHeight(root, 50);
|
||||
@@ -1122,6 +1166,8 @@ TEST(YogaTest, min_height_overrides_height) {
|
||||
|
||||
TEST(YogaTest, max_height_overrides_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetHeight(root, 200);
|
||||
@@ -1147,6 +1193,8 @@ TEST(YogaTest, max_height_overrides_height) {
|
||||
|
||||
TEST(YogaTest, min_max_percent_no_width_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetAlignItems(root, YGAlignFlexStart);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, padding_no_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPadding(root, YGEdgeLeft, 10);
|
||||
@@ -40,6 +42,8 @@ TEST(YogaTest, padding_no_size) {
|
||||
|
||||
TEST(YogaTest, padding_container_match_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPadding(root, YGEdgeLeft, 10);
|
||||
@@ -82,6 +86,8 @@ TEST(YogaTest, padding_container_match_child) {
|
||||
|
||||
TEST(YogaTest, padding_flex_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPadding(root, YGEdgeLeft, 10);
|
||||
@@ -126,6 +132,8 @@ TEST(YogaTest, padding_flex_child) {
|
||||
|
||||
TEST(YogaTest, padding_stretch_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPadding(root, YGEdgeLeft, 10);
|
||||
@@ -169,6 +177,8 @@ TEST(YogaTest, padding_stretch_child) {
|
||||
|
||||
TEST(YogaTest, padding_center_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -214,6 +224,8 @@ TEST(YogaTest, padding_center_child) {
|
||||
|
||||
TEST(YogaTest, child_with_padding_align_end) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyFlexEnd);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, percentage_width_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -54,6 +56,8 @@ TEST(YogaTest, percentage_width_height) {
|
||||
|
||||
TEST(YogaTest, percentage_position_left_top) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -97,6 +101,8 @@ TEST(YogaTest, percentage_position_left_top) {
|
||||
|
||||
TEST(YogaTest, percentage_position_bottom_right) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -140,6 +146,8 @@ TEST(YogaTest, percentage_position_bottom_right) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -196,6 +204,8 @@ TEST(YogaTest, percentage_flex_basis) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_cross) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -251,6 +261,8 @@ TEST(YogaTest, percentage_flex_basis_cross) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_main_max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -309,6 +321,8 @@ TEST(YogaTest, percentage_flex_basis_main_max_height) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_cross_max_height) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -366,6 +380,8 @@ TEST(YogaTest, percentage_flex_basis_cross_max_height) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_main_max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -424,6 +440,8 @@ TEST(YogaTest, percentage_flex_basis_main_max_width) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_cross_max_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -481,6 +499,8 @@ TEST(YogaTest, percentage_flex_basis_cross_max_width) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_main_min_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -539,6 +559,8 @@ TEST(YogaTest, percentage_flex_basis_main_min_width) {
|
||||
|
||||
TEST(YogaTest, percentage_flex_basis_cross_min_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -596,6 +618,8 @@ TEST(YogaTest, percentage_flex_basis_cross_min_width) {
|
||||
|
||||
TEST(YogaTest, percentage_multiple_nested_with_padding_margin_and_percentage_values) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -705,6 +729,8 @@ TEST(YogaTest, percentage_multiple_nested_with_padding_margin_and_percentage_val
|
||||
|
||||
TEST(YogaTest, percentage_margin_should_calculate_based_only_on_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -763,6 +789,8 @@ TEST(YogaTest, percentage_margin_should_calculate_based_only_on_width) {
|
||||
|
||||
TEST(YogaTest, percentage_padding_should_calculate_based_only_on_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -821,6 +849,8 @@ TEST(YogaTest, percentage_padding_should_calculate_based_only_on_width) {
|
||||
|
||||
TEST(YogaTest, percentage_absolute_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 200);
|
||||
@@ -864,6 +894,8 @@ TEST(YogaTest, percentage_absolute_position) {
|
||||
|
||||
TEST(YogaTest, percentage_width_height_undefined_parent_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
|
||||
@@ -902,6 +934,8 @@ TEST(YogaTest, percentage_width_height_undefined_parent_size) {
|
||||
|
||||
TEST(YogaTest, percent_within_flex_grow) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -984,6 +1018,8 @@ TEST(YogaTest, percent_within_flex_grow) {
|
||||
|
||||
TEST(YogaTest, percentage_container_in_wrapping_container) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetJustifyContent(root, YGJustifyCenter);
|
||||
@@ -1070,6 +1106,8 @@ TEST(YogaTest, percentage_container_in_wrapping_container) {
|
||||
|
||||
TEST(YogaTest, percent_absolute_position) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 60);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, rounding_flex_basis_flex_grow_row_width_of_100) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -81,6 +83,8 @@ TEST(YogaTest, rounding_flex_basis_flex_grow_row_width_of_100) {
|
||||
|
||||
TEST(YogaTest, rounding_flex_basis_flex_grow_row_prime_number_width) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -177,6 +181,8 @@ TEST(YogaTest, rounding_flex_basis_flex_grow_row_prime_number_width) {
|
||||
|
||||
TEST(YogaTest, rounding_flex_basis_flex_shrink_row) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -246,6 +252,8 @@ TEST(YogaTest, rounding_flex_basis_flex_shrink_row) {
|
||||
|
||||
TEST(YogaTest, rounding_flex_basis_overrides_main_size) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -317,6 +325,8 @@ TEST(YogaTest, rounding_flex_basis_overrides_main_size) {
|
||||
|
||||
TEST(YogaTest, rounding_total_fractial) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 87.4f);
|
||||
@@ -388,6 +398,8 @@ TEST(YogaTest, rounding_total_fractial) {
|
||||
|
||||
TEST(YogaTest, rounding_total_fractial_nested) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 87.4f);
|
||||
@@ -493,6 +505,8 @@ TEST(YogaTest, rounding_total_fractial_nested) {
|
||||
|
||||
TEST(YogaTest, rounding_fractial_input_1) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -564,6 +578,8 @@ TEST(YogaTest, rounding_fractial_input_1) {
|
||||
|
||||
TEST(YogaTest, rounding_fractial_input_2) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -635,6 +651,8 @@ TEST(YogaTest, rounding_fractial_input_2) {
|
||||
|
||||
TEST(YogaTest, rounding_fractial_input_3) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPosition(root, YGEdgeTop, 0.3f);
|
||||
@@ -707,6 +725,8 @@ TEST(YogaTest, rounding_fractial_input_3) {
|
||||
|
||||
TEST(YogaTest, rounding_fractial_input_4) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetPosition(root, YGEdgeTop, 0.7f);
|
||||
@@ -779,6 +799,8 @@ TEST(YogaTest, rounding_fractial_input_4) {
|
||||
|
||||
TEST(YogaTest, rounding_inner_node_controversy_horizontal) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
@@ -864,6 +886,8 @@ TEST(YogaTest, rounding_inner_node_controversy_horizontal) {
|
||||
|
||||
TEST(YogaTest, rounding_inner_node_controversy_vertical) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetHeight(root, 320);
|
||||
@@ -948,6 +972,8 @@ TEST(YogaTest, rounding_inner_node_controversy_vertical) {
|
||||
|
||||
TEST(YogaTest, rounding_inner_node_controversy_combined) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetFlexDirection(root, YGFlexDirectionRow);
|
||||
|
@@ -13,6 +13,8 @@
|
||||
|
||||
TEST(YogaTest, nested_overflowing_child) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -66,6 +68,8 @@ TEST(YogaTest, nested_overflowing_child) {
|
||||
|
||||
TEST(YogaTest, nested_overflowing_child_in_constraint_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
@@ -121,6 +125,8 @@ TEST(YogaTest, nested_overflowing_child_in_constraint_parent) {
|
||||
|
||||
TEST(YogaTest, parent_wrap_child_size_overflowing_parent) {
|
||||
const YGConfigRef config = YGConfigNew();
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureAbsolutePercentageAgainstPaddingEdge, true);
|
||||
YGConfigSetExperimentalFeatureEnabled(config, YGExperimentalFeatureFixAbsoluteTrailingColumnMargin, true);
|
||||
|
||||
const YGNodeRef root = YGNodeNewWithConfig(config);
|
||||
YGNodeStyleSetWidth(root, 100);
|
||||
|
Reference in New Issue
Block a user