Skip to content

Commit

Permalink
fix selenium tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rbuels committed Aug 17, 2012
1 parent d7265ab commit 1e20f53
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
13 changes: 10 additions & 3 deletions tests/selenium_tests/volvox_biodb_test.py
Expand Up @@ -61,7 +61,7 @@ def bigwig( self ):
def sequence( self ):
self.do_typed_query( '0..80' );
time.sleep(0.2);
sequence_div_xpath_templ = "/html//div[contains(@class,'sequence')][contains(.,'%s')]"
sequence_div_xpath_templ = "/html//div[contains(@class,'sequence')]//*[contains(.,'%s')]"
sequence_div_xpath_1 = sequence_div_xpath_templ % 'aacaACGG';
self.assert_element( sequence_div_xpath_1)
self.turn_off_track( 'DNA' );
Expand All @@ -85,7 +85,14 @@ def context_menus( self ):

# right-click one of them
self.actionchains() \
.context_click(feature_elements[20]) \
.move_to_element(feature_elements[20]) \
.perform()

# wait for the context menu to generate
time.sleep(0.1)

self.actionchains() \
.context_click( feature_elements[20] ) \
.move_by_offset( 20, 55 ) \
.click() \
.perform()
Expand Down Expand Up @@ -122,7 +129,7 @@ def wiggle( self ):
def search_f15( self ):

# check that a f15 feature label is not yet in the DOM
xpath = "//div[@class='feature-label'][contains(.,'f15')]"
xpath = "//div[@class='feature-label']//*[contains(.,'f15')]"
# check that f15 is not already in the DOM at load time
self.assert_no_element( xpath )

Expand Down
2 changes: 1 addition & 1 deletion tests/selenium_tests/yeast_biodb_test.py
Expand Up @@ -75,7 +75,7 @@ def sequence( self ):
def search_yal024c( self ):

# check that a YAL024C feature label is not yet in the DOM
yal024_label_xpath = "//div[@class='feature-label'][contains(.,'YAL024C')]"
yal024_label_xpath = "//div[@class='feature-label']//*[contains(.,'YAL024C')]"
self.assert_no_element( yal024_label_xpath )

# Find the query box and put YAL024C into it and hit enter
Expand Down

0 comments on commit 1e20f53

Please sign in to comment.