original_docstring: Deploy ClickHouse Operator on Altinity dashboard.
docstring: Deploy ClickHouse Operator on Altinity dashboard.
docstring_tokens: Deploy ClickHouse Operator on Altinity dashboard .
code: def deploy_cho_install_ch(self, timeout=15):
      """Deploy ClickHouse Operator on Altinity dashboard."""
      driver: WebDriver = self.context.driver
      cho_tab="/html/body/div[1]/div/div/div/nav/ul/li[2]/a"
      add_cho="/html/body/div[1]/div/main/section/div/div[2]/button"
      select_ns="//*[@id='pf-context-selector-toggle-id-0']"
      select_default_ns="/html/body/div[6]/div/div/ul/li[1]/button"
      click_deploy="/html/body/div[5]/div/div/div/footer/button[1]"
      ch_install="/html/body/div[1]/div/div/div/nav/ul/li[3]/a"
      select_template="//*[@id='pf-context-selector-toggle-id-0']"
      select_template_dropdown="/html/body/div[7]/div/div/ul/li[12]/button"
      select_ns_chi="//*[@id='pf-context-selector-toggle-id-0']"
      select_type="//*[@id='pf-context-selector-search-button-id-0']"
      select_ns_search="/html/body/div[8]/div/div/div/div/input"
      select_ns_search_icon="//*[@id='pf-context-selector-search-button-id-0']"
      select_ns_default_chi="/html/body/div[8]/div/div/ul/li[1]/button"
      Create_btn_chi="/html/body/div[5]/div/div/div/footer/div/div[4]/button[1]"
  
      chi_toggle_btn="/html/body/div[1]/div/main/section/table/tbody/tr[1]/td[7]/div"
      cho_toggle_btn="/html/body/div[1]/div/main/section/table/tbody/tr[1]/td[6]/div"
  
      with Given("Adash is visible in chrome"):
          with When("I click on `ClickHouse Operator` tab in the Adash"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=cho_tab
              )
  
              cho_tabs = driver.find_element(
                  SelectBy.XPATH, cho_tab
              )
              cho_tabs.click()
  
          with And("I click on `+` button to add ClickHouse Operator"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=add_cho
              )         
  
              add_chos = driver.find_element(
                  SelectBy.XPATH, add_cho
              )
              add_chos.click()
  
          with And("I click on `Select a Namespace:` drop down"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_ns
              )         
  
              select_nss = driver.find_element(
                  SelectBy.XPATH, select_ns
              )
              select_nss.click()
  
          with And("I click on `default` namespace"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_default_ns
              )   
  
              select_default_nss = driver.find_element(
                  SelectBy.XPATH, select_default_ns
              )
              select_default_nss.click()
  
          with And("I click on `Deploy` button"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=click_deploy
              )   
  
              click_deploys = driver.find_element(
                  SelectBy.XPATH, click_deploy
              )
              click_deploys.click()
              time.sleep(2)
  
          with And("I wait until `ClickHouse Operator` become visible"):
              for attempt in retries(count=5, timeout=timeout, delay=2):
                  with attempt:            
                      wait_for_element_to_be_visible(
                      select_type=SelectBy.XPATH, element=cho_toggle_btn
                      )
  
          with And("I click on `ClickHouse Installations` tab"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=ch_install
              )   
  
              ch_installs = driver.find_element(
                  SelectBy.XPATH, ch_install
              )
              ch_installs.click()
  
          with And("I click on `+` button to add ClickHouse Installations"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=add_cho
              )   
  
              add_chos = driver.find_element(
                  SelectBy.XPATH, add_cho
              )
              add_chos.click()
              time.sleep(2)
  
          with And("I click on template example dropdown"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_template
              )   
  
              select_templates = driver.find_element(
                  SelectBy.XPATH, select_template
              )
              select_templates.click()
  
          with And("I select a installation template"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_template_dropdown
              )   
  
              select_template_dropdowns = driver.find_element(
                  SelectBy.XPATH, select_template_dropdown
              )
              select_template_dropdowns.click()
  
          with And("I click on `Select a Namespace To Deploy To:` dropdown"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_ns_chi
              )   
  
              select_ns_chis = driver.find_element(
                  SelectBy.XPATH, select_ns_chi
              )
              select_ns_chis.click()
  
              wait_for_element_to_be_clickable(
                  select_type=SelectBy.XPATH,
                  element=select_ns_search_icon,
              )
  
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_ns_search
              )   
  
              select_ns_searchs = driver.find_element(
                  SelectBy.XPATH, select_ns_search
              )
              select_ns_searchs.send_keys(Keys.TAB)
  
              select_ns_search_icons = driver.find_element(
                  SelectBy.XPATH, select_ns_search_icon
              )
              select_ns_search_icons.send_keys(Keys.TAB)
  
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=select_ns_default_chi
              )   
  
              select_ns_default_chis = driver.find_element(
                  SelectBy.XPATH, select_ns_default_chi
              )
              select_ns_default_chis.send_keys(Keys.ENTER)
  
          with And("I click `Create` button"):
              wait_for_element_to_be_clickable(
              timeout=timeout, select_type=SelectBy.XPATH, element=Create_btn_chi
              )               
              Create_btn_chis = driver.find_element(
                  SelectBy.XPATH,Create_btn_chi
                  ,
              )
              Create_btn_chis.click()
code_tokens: def deploy_cho_install_ch ( self , timeout = 15 ) : driver : WebDriver = self . context . driver cho_tab = "/html/body/div[1]/div/div/div/nav/ul/li[2]/a" add_cho = "/html/body/div[1]/div/main/section/div/div[2]/button" select_ns = "//*[@id='pf-context-selector-toggle-id-0']" select_default_ns = "/html/body/div[6]/div/div/ul/li[1]/button" click_deploy = "/html/body/div[5]/div/div/div/footer/button[1]" ch_install = "/html/body/div[1]/div/div/div/nav/ul/li[3]/a" select_template = "//*[@id='pf-context-selector-toggle-id-0']" select_template_dropdown = "/html/body/div[7]/div/div/ul/li[12]/button" select_ns_chi = "//*[@id='pf-context-selector-toggle-id-0']" select_type = "//*[@id='pf-context-selector-search-button-id-0']" select_ns_search = "/html/body/div[8]/div/div/div/div/input" select_ns_search_icon = "//*[@id='pf-context-selector-search-button-id-0']" select_ns_default_chi = "/html/body/div[8]/div/div/ul/li[1]/button" Create_btn_chi = "/html/body/div[5]/div/div/div/footer/div/div[4]/button[1]" chi_toggle_btn = "/html/body/div[1]/div/main/section/table/tbody/tr[1]/td[7]/div" cho_toggle_btn = "/html/body/div[1]/div/main/section/table/tbody/tr[1]/td[6]/div" with Given ( "Adash is visible in chrome" ) : with When ( "I click on `ClickHouse Operator` tab in the Adash" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = cho_tab ) cho_tabs = driver . find_element ( SelectBy . XPATH , cho_tab ) cho_tabs . click ( ) with And ( "I click on `+` button to add ClickHouse Operator" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = add_cho ) add_chos = driver . find_element ( SelectBy . XPATH , add_cho ) add_chos . click ( ) with And ( "I click on `Select a Namespace:` drop down" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_ns ) select_nss = driver . find_element ( SelectBy . XPATH , select_ns ) select_nss . click ( ) with And ( "I click on `default` namespace" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_default_ns ) select_default_nss = driver . find_element ( SelectBy . XPATH , select_default_ns ) select_default_nss . click ( ) with And ( "I click on `Deploy` button" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = click_deploy ) click_deploys = driver . find_element ( SelectBy . XPATH , click_deploy ) click_deploys . click ( ) time . sleep ( 2 ) with And ( "I wait until `ClickHouse Operator` become visible" ) : for attempt in retries ( count = 5 , timeout = timeout , delay = 2 ) : with attempt : wait_for_element_to_be_visible ( select_type = SelectBy . XPATH , element = cho_toggle_btn ) with And ( "I click on `ClickHouse Installations` tab" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = ch_install ) ch_installs = driver . find_element ( SelectBy . XPATH , ch_install ) ch_installs . click ( ) with And ( "I click on `+` button to add ClickHouse Installations" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = add_cho ) add_chos = driver . find_element ( SelectBy . XPATH , add_cho ) add_chos . click ( ) time . sleep ( 2 ) with And ( "I click on template example dropdown" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_template ) select_templates = driver . find_element ( SelectBy . XPATH , select_template ) select_templates . click ( ) with And ( "I select a installation template" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_template_dropdown ) select_template_dropdowns = driver . find_element ( SelectBy . XPATH , select_template_dropdown ) select_template_dropdowns . click ( ) with And ( "I click on `Select a Namespace To Deploy To:` dropdown" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_ns_chi ) select_ns_chis = driver . find_element ( SelectBy . XPATH , select_ns_chi ) select_ns_chis . click ( ) wait_for_element_to_be_clickable ( select_type = SelectBy . XPATH , element = select_ns_search_icon , ) wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_ns_search ) select_ns_searchs = driver . find_element ( SelectBy . XPATH , select_ns_search ) select_ns_searchs . send_keys ( Keys . TAB ) select_ns_search_icons = driver . find_element ( SelectBy . XPATH , select_ns_search_icon ) select_ns_search_icons . send_keys ( Keys . TAB ) wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = select_ns_default_chi ) select_ns_default_chis = driver . find_element ( SelectBy . XPATH , select_ns_default_chi ) select_ns_default_chis . send_keys ( Keys . ENTER ) with And ( "I click `Create` button" ) : wait_for_element_to_be_clickable ( timeout = timeout , select_type = SelectBy . XPATH , element = Create_btn_chi ) Create_btn_chis = driver . find_element ( SelectBy . XPATH , Create_btn_chi , ) Create_btn_chis . click ( )
short_docstring: Deploy ClickHouse Operator on Altinity dashboard.
short_docstring_tokens: Deploy ClickHouse Operator on Altinity dashboard .
comment: """Deploy ClickHouse Operator on Altinity dashboard."""