demo/expand/index.js
function(cell, portId) {
    console.assert(cell.isVisible());
    console.assert(!cell.portProp(portId, 'collapsed'), 'port ' + portId + ' on ' + cell.id + ' should be  expanded');

}
function(cell, portId) {
    console.assert(cell.isVisible());
    console.assert(!cell.portProp(portId, 'collapsed'), 'port ' + portId + ' on ' + cell.id + ' should be  expanded');

}
function ( cell , portId ) { console . assert ( cell . isVisible ( ) ) ; console . assert ( ! cell . portProp ( portId , 'collapsed' ) , 'port ' + portId + ' on ' + cell . id + ' should be  expanded' ) ; }
Simple unit testing
Simple unit testing