position: absolute and alignSelf

This commit is contained in:
Christopher Chedeau
2014-04-21 14:58:44 -07:00
parent 72e2d959f2
commit 9760cfd323
2 changed files with 32 additions and 18 deletions

View File

@@ -493,6 +493,17 @@ describe('Layout', function() {
);
});
it('should layout node with position: absolute, padding and alignSelf: center', function() {
testLayout(
{style : {}, children : [
{style: {paddingRight: 12, alignSelf: 'center', position: 'absolute'}}
]},
{width: 0, height: 0, top: 0, left: 0, children: [
{width: 12, height: 0, top: 0, left: 0}
]}
);
})
it('should layout randomly', function() {
function RNG(seed) {
this.state = seed;