muu

DEPRECATED lightweight JS framework
git clone https://git.ce9e.org/muu.git

commit
5aef968f3a79bb79a9efeeb2f8e1f19a7fee2c3b
parent
890cf4261a746ff7984dca0dd1681eb190aa1779
Author
Tobias Bengfort <tobias.bengfort@gmx.net>
Date
2015-09-10 09:44
test updateDOM muu-isolate behavior

Diffstat

M test/test-update-dom.js 12 ++++++++++++

1 files changed, 12 insertions, 0 deletions


diff --git a/test/test-update-dom.js b/test/test-update-dom.js

@@ -99,5 +99,17 @@ define(['muu-update-dom'], function(updateDOM) {
   99    99             expect(n(target.innerHTML)).to.contain('class="test"');
  100   100             expect(target.querySelector('input').checked).to.be.ok();
  101   101         });
   -1   102         it('does not change children of .muu-isolate', function() {
   -1   103             source.innerHTML = '<div class="muu-isolate"><span>huhu</span></div>';
   -1   104             target.innerHTML = '<div class="muu-isolate"><div>haha</div></div>';
   -1   105             updateDOM(target, source);
   -1   106             expect(n(target.innerHTML)).to.be('<div class="muu-isolate"><div>haha</div></div>');
   -1   107         });
   -1   108         it('does change attributes of .muu-isolate', function() {
   -1   109             source.innerHTML = '<div class="muu-isolate" data-name="foo"></div>';
   -1   110             target.innerHTML = '<div class="muu-isolate" data-name="bar"></div>';
   -1   111             updateDOM(target, source);
   -1   112             expect(n(target.innerHTML)).to.be('<div class="muu-isolate" data-name="foo"></div>');
   -1   113         });
  102   114     });
  103   115 });