#20, #11: _locate_element() is now tested. Fixed few bugs found by tests.