Add data-disabled
to test fixtures (#1286)
Summary: Pull Request resolved: https://github.com/facebook/yoga/pull/1286 This can be marked in fixtures to skip a test without commenting it out. We add one more usage of this. The same functionality existed (unused) before for `experiments`, which I changed to `data-experiments`. Formatting of JS tests changed to be closer to what Prettier would output, and to remove usage of `Yoga.UNDEFINED` which doesn't existi and just resolves to `undefined` (this is converted to NaN by the wrapper layer). Reviewed By: yungsters Differential Revision: D45723003 fbshipit-source-id: 337af319ab1c1c12047d6579da8c7e63b4f1537a
This commit is contained in:
committed by
Facebook GitHub Bot
parent
e409bfb43a
commit
e769dd97d8
@@ -7,7 +7,7 @@
|
||||
|
||||
// @generated by gentest/gentest.rb from gentest/fixtures/YGFlexWrapTest.html
|
||||
|
||||
test("wrap_column", () => {
|
||||
test('wrap_column', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -38,7 +38,7 @@ test("wrap_column", () => {
|
||||
root_child3.setWidth(30);
|
||||
root_child3.setHeight(30);
|
||||
root.insertChild(root_child3, 3);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -65,7 +65,7 @@ test("wrap_column", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -92,14 +92,14 @@ test("wrap_column", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_row", () => {
|
||||
test('wrap_row', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -131,7 +131,7 @@ test("wrap_row", () => {
|
||||
root_child3.setWidth(30);
|
||||
root_child3.setHeight(30);
|
||||
root.insertChild(root_child3, 3);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -158,7 +158,7 @@ test("wrap_row", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -185,14 +185,14 @@ test("wrap_row", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_row_align_items_flex_end", () => {
|
||||
test('wrap_row_align_items_flex_end', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -225,7 +225,7 @@ test("wrap_row_align_items_flex_end", () => {
|
||||
root_child3.setWidth(30);
|
||||
root_child3.setHeight(30);
|
||||
root.insertChild(root_child3, 3);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -252,7 +252,7 @@ test("wrap_row_align_items_flex_end", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -279,14 +279,14 @@ test("wrap_row_align_items_flex_end", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_row_align_items_center", () => {
|
||||
test('wrap_row_align_items_center', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -319,7 +319,7 @@ test("wrap_row_align_items_center", () => {
|
||||
root_child3.setWidth(30);
|
||||
root_child3.setHeight(30);
|
||||
root.insertChild(root_child3, 3);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -346,7 +346,7 @@ test("wrap_row_align_items_center", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -373,14 +373,14 @@ test("wrap_row_align_items_center", () => {
|
||||
expect(root_child3.getComputedWidth()).toBe(30);
|
||||
expect(root_child3.getComputedHeight()).toBe(30);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("flex_wrap_children_with_min_main_overriding_flex_basis", () => {
|
||||
test('flex_wrap_children_with_min_main_overriding_flex_basis', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -404,7 +404,7 @@ test("flex_wrap_children_with_min_main_overriding_flex_basis", () => {
|
||||
root_child1.setMinWidth(55);
|
||||
root_child1.setHeight(50);
|
||||
root.insertChild(root_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -421,7 +421,7 @@ test("flex_wrap_children_with_min_main_overriding_flex_basis", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(55);
|
||||
expect(root_child1.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -438,14 +438,14 @@ test("flex_wrap_children_with_min_main_overriding_flex_basis", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(55);
|
||||
expect(root_child1.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("flex_wrap_wrap_to_child_height", () => {
|
||||
test('flex_wrap_wrap_to_child_height', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -474,7 +474,7 @@ test("flex_wrap_wrap_to_child_height", () => {
|
||||
root_child1.setWidth(100);
|
||||
root_child1.setHeight(100);
|
||||
root.insertChild(root_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -501,7 +501,7 @@ test("flex_wrap_wrap_to_child_height", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(100);
|
||||
expect(root_child1.getComputedHeight()).toBe(100);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -528,14 +528,14 @@ test("flex_wrap_wrap_to_child_height", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(100);
|
||||
expect(root_child1.getComputedHeight()).toBe(100);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("flex_wrap_align_stretch_fits_one_row", () => {
|
||||
test('flex_wrap_align_stretch_fits_one_row', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -556,7 +556,7 @@ test("flex_wrap_align_stretch_fits_one_row", () => {
|
||||
const root_child1 = Yoga.Node.create(config);
|
||||
root_child1.setWidth(50);
|
||||
root.insertChild(root_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -573,7 +573,7 @@ test("flex_wrap_align_stretch_fits_one_row", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(50);
|
||||
expect(root_child1.getComputedHeight()).toBe(0);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -590,14 +590,14 @@ test("flex_wrap_align_stretch_fits_one_row", () => {
|
||||
expect(root_child1.getComputedWidth()).toBe(50);
|
||||
expect(root_child1.getComputedHeight()).toBe(0);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_row_align_content_flex_start", () => {
|
||||
test('wrap_reverse_row_align_content_flex_start', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -634,7 +634,7 @@ test("wrap_reverse_row_align_content_flex_start", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -666,7 +666,7 @@ test("wrap_reverse_row_align_content_flex_start", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -698,14 +698,14 @@ test("wrap_reverse_row_align_content_flex_start", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_row_align_content_center", () => {
|
||||
test('wrap_reverse_row_align_content_center', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -743,7 +743,7 @@ test("wrap_reverse_row_align_content_center", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -775,7 +775,7 @@ test("wrap_reverse_row_align_content_center", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -807,14 +807,14 @@ test("wrap_reverse_row_align_content_center", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_row_single_line_different_size", () => {
|
||||
test('wrap_reverse_row_single_line_different_size', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -851,7 +851,7 @@ test("wrap_reverse_row_single_line_different_size", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -883,7 +883,7 @@ test("wrap_reverse_row_single_line_different_size", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -915,14 +915,14 @@ test("wrap_reverse_row_single_line_different_size", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_row_align_content_stretch", () => {
|
||||
test('wrap_reverse_row_align_content_stretch', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -960,7 +960,7 @@ test("wrap_reverse_row_align_content_stretch", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -992,7 +992,7 @@ test("wrap_reverse_row_align_content_stretch", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1024,14 +1024,14 @@ test("wrap_reverse_row_align_content_stretch", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_row_align_content_space_around", () => {
|
||||
test('wrap_reverse_row_align_content_space_around', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1069,7 +1069,7 @@ test("wrap_reverse_row_align_content_space_around", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1101,7 +1101,7 @@ test("wrap_reverse_row_align_content_space_around", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1133,14 +1133,14 @@ test("wrap_reverse_row_align_content_space_around", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_reverse_column_fixed_size", () => {
|
||||
test('wrap_reverse_column_fixed_size', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1178,7 +1178,7 @@ test("wrap_reverse_column_fixed_size", () => {
|
||||
root_child4.setWidth(30);
|
||||
root_child4.setHeight(50);
|
||||
root.insertChild(root_child4, 4);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1210,7 +1210,7 @@ test("wrap_reverse_column_fixed_size", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1242,14 +1242,14 @@ test("wrap_reverse_column_fixed_size", () => {
|
||||
expect(root_child4.getComputedWidth()).toBe(30);
|
||||
expect(root_child4.getComputedHeight()).toBe(50);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrapped_row_within_align_items_center", () => {
|
||||
test('wrapped_row_within_align_items_center', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1276,7 +1276,7 @@ test("wrapped_row_within_align_items_center", () => {
|
||||
root_child0_child1.setWidth(80);
|
||||
root_child0_child1.setHeight(80);
|
||||
root_child0.insertChild(root_child0_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1298,7 +1298,7 @@ test("wrapped_row_within_align_items_center", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1320,14 +1320,14 @@ test("wrapped_row_within_align_items_center", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrapped_row_within_align_items_flex_start", () => {
|
||||
test('wrapped_row_within_align_items_flex_start', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1354,7 +1354,7 @@ test("wrapped_row_within_align_items_flex_start", () => {
|
||||
root_child0_child1.setWidth(80);
|
||||
root_child0_child1.setHeight(80);
|
||||
root_child0.insertChild(root_child0_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1376,7 +1376,7 @@ test("wrapped_row_within_align_items_flex_start", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1398,14 +1398,14 @@ test("wrapped_row_within_align_items_flex_start", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrapped_row_within_align_items_flex_end", () => {
|
||||
test('wrapped_row_within_align_items_flex_end', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1432,7 +1432,7 @@ test("wrapped_row_within_align_items_flex_end", () => {
|
||||
root_child0_child1.setWidth(80);
|
||||
root_child0_child1.setHeight(80);
|
||||
root_child0.insertChild(root_child0_child1, 1);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1454,7 +1454,7 @@ test("wrapped_row_within_align_items_flex_end", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1476,14 +1476,14 @@ test("wrapped_row_within_align_items_flex_end", () => {
|
||||
expect(root_child0_child1.getComputedWidth()).toBe(80);
|
||||
expect(root_child0_child1.getComputedHeight()).toBe(80);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrapped_column_max_height", () => {
|
||||
test('wrapped_column_max_height', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1518,7 +1518,7 @@ test("wrapped_column_max_height", () => {
|
||||
root_child2.setWidth(100);
|
||||
root_child2.setHeight(100);
|
||||
root.insertChild(root_child2, 2);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1540,7 +1540,7 @@ test("wrapped_column_max_height", () => {
|
||||
expect(root_child2.getComputedWidth()).toBe(100);
|
||||
expect(root_child2.getComputedHeight()).toBe(100);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1562,14 +1562,14 @@ test("wrapped_column_max_height", () => {
|
||||
expect(root_child2.getComputedWidth()).toBe(100);
|
||||
expect(root_child2.getComputedHeight()).toBe(100);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrapped_column_max_height_flex", () => {
|
||||
test('wrapped_column_max_height_flex', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1610,7 +1610,7 @@ test("wrapped_column_max_height_flex", () => {
|
||||
root_child2.setWidth(100);
|
||||
root_child2.setHeight(100);
|
||||
root.insertChild(root_child2, 2);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1632,7 +1632,7 @@ test("wrapped_column_max_height_flex", () => {
|
||||
expect(root_child2.getComputedWidth()).toBe(100);
|
||||
expect(root_child2.getComputedHeight()).toBe(100);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1654,14 +1654,14 @@ test("wrapped_column_max_height_flex", () => {
|
||||
expect(root_child2.getComputedWidth()).toBe(100);
|
||||
expect(root_child2.getComputedHeight()).toBe(100);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_nodes_with_content_sizing_overflowing_margin", () => {
|
||||
test('wrap_nodes_with_content_sizing_overflowing_margin', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1695,7 +1695,7 @@ test("wrap_nodes_with_content_sizing_overflowing_margin", () => {
|
||||
root_child0_child1_child0.setWidth(40);
|
||||
root_child0_child1_child0.setHeight(40);
|
||||
root_child0_child1.insertChild(root_child0_child1_child0, 0);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1727,7 +1727,7 @@ test("wrap_nodes_with_content_sizing_overflowing_margin", () => {
|
||||
expect(root_child0_child1_child0.getComputedWidth()).toBe(40);
|
||||
expect(root_child0_child1_child0.getComputedHeight()).toBe(40);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1759,14 +1759,14 @@ test("wrap_nodes_with_content_sizing_overflowing_margin", () => {
|
||||
expect(root_child0_child1_child0.getComputedWidth()).toBe(40);
|
||||
expect(root_child0_child1_child0.getComputedHeight()).toBe(40);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
config.free();
|
||||
}
|
||||
});
|
||||
test("wrap_nodes_with_content_sizing_margin_cross", () => {
|
||||
test('wrap_nodes_with_content_sizing_margin_cross', () => {
|
||||
const config = Yoga.Config.create();
|
||||
let root;
|
||||
|
||||
@@ -1800,7 +1800,7 @@ test("wrap_nodes_with_content_sizing_margin_cross", () => {
|
||||
root_child0_child1_child0.setWidth(40);
|
||||
root_child0_child1_child0.setHeight(40);
|
||||
root_child0_child1.insertChild(root_child0_child1_child0, 0);
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_LTR);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_LTR);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1832,7 +1832,7 @@ test("wrap_nodes_with_content_sizing_margin_cross", () => {
|
||||
expect(root_child0_child1_child0.getComputedWidth()).toBe(40);
|
||||
expect(root_child0_child1_child0.getComputedHeight()).toBe(40);
|
||||
|
||||
root.calculateLayout(Yoga.UNDEFINED, Yoga.UNDEFINED, Yoga.DIRECTION_RTL);
|
||||
root.calculateLayout(undefined, undefined, Yoga.DIRECTION_RTL);
|
||||
|
||||
expect(root.getComputedLeft()).toBe(0);
|
||||
expect(root.getComputedTop()).toBe(0);
|
||||
@@ -1864,7 +1864,7 @@ test("wrap_nodes_with_content_sizing_margin_cross", () => {
|
||||
expect(root_child0_child1_child0.getComputedWidth()).toBe(40);
|
||||
expect(root_child0_child1_child0.getComputedHeight()).toBe(40);
|
||||
} finally {
|
||||
if (typeof root !== "undefined") {
|
||||
if (typeof root !== 'undefined') {
|
||||
root.freeRecursive();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user