add tests for flexWrap
This commit is contained in:
@@ -1044,7 +1044,7 @@ describe('Layout', function() {
|
||||
);
|
||||
});
|
||||
|
||||
it('should calcluate left properly with position: absolute right, width, and no parent dimensions', function() {
|
||||
it('should calculate left properly with position: absolute right, width, and no parent dimensions', function() {
|
||||
testLayout(
|
||||
{style: {}, children: [
|
||||
{style: {width: 10, position: 'absolute', right: 0}}
|
||||
@@ -1055,6 +1055,22 @@ describe('Layout', function() {
|
||||
);
|
||||
});
|
||||
|
||||
xit('should layout flex-wrap', function() {
|
||||
testLayout(
|
||||
{style: {flexWrap: 'wrap', flexDirection: 'row', width: 100}, children: [
|
||||
{style: {width: 40, height: 10}},
|
||||
{style: {width: 40, height: 10}},
|
||||
{style: {flex: 1}},
|
||||
{style: {width: 40, height: 10}},
|
||||
]},
|
||||
{width: 100, height: 20, top: 0, left: 0, children: [
|
||||
{width: 40, height: 10, top: 0, left: 0},
|
||||
{width: 40, height: 10, top: 0, left: 40},
|
||||
{width: 40, height: 10, top: 10, left: 0}
|
||||
]}
|
||||
);
|
||||
});
|
||||
|
||||
xit('should layout text with alignItems: stretch', function() {
|
||||
testLayout(
|
||||
{style: {width: 80, padding: 7, alignItems: 'stretch', measure: text(texts.big)}},
|
||||
|
Reference in New Issue
Block a user