add tests

This commit is contained in:
rolux 2014-09-22 14:16:00 +02:00
parent 5e4ac3492b
commit c041263c79

View file

@ -12,6 +12,10 @@ Ox.$ <f> Generic HTML element, mimics jQuery
false
> Ox.$('<div>').addClass('red').addClass('red')[0].className
'red'
> Ox.$('<a>').append(Ox.$('<b>')).children('b').length
1
> Ox.$('<b>').appendTo(Ox.$('<a>')).parents('a').length
1
> Ox.$('<div>').attr({id: 'red'}).attr('id')
'red'
> Ox.$('<div>').attr({id: 'red'}).removeAttr('id').attr('id')
@ -22,10 +26,10 @@ Ox.$ <f> Generic HTML element, mimics jQuery
'red'
> Ox.$('<div>').html('red').empty().html()
''
> Ox.$('<input>').val('red').val()
'red'
> !!Ox.$('<div>').on({click: function(e) { Ox.test(e.type, 'click'); }}).trigger('click')
true
> Ox.$('<input>').val('red').val()
'red'
@*/
Ox.$ = Ox.element = function $(value) {