title: Unable to select html element by class name in python selenium
body: <p>I am trying to select <strong>I NEED THIS TEXT</strong> from the last line of the following html code and did not yet have success so far:</p>
  
  <pre><code>        &lt;div class="warn"&gt;
  &lt;div class="row container pv2"&gt;
      &lt;div class="col xs12"&gt;
          &lt;div class="display-table-cell b-text_copy-4 pr1"&gt;
              &lt;i class="msg-icon b-icon b-icon-warn"&gt;&lt;/i&gt;
          &lt;/div&gt;
          &lt;div class="display-table-cell b-text_copy-2 b-text_weight-bold"&gt;
                      &lt;div&gt; I NEED THIS TEXT &lt;a href=https://somelink/contact.html target=_blank&gt;contact us&lt;/a&gt;.&lt;/div&gt;
  </code></pre>
  
  <p><strong>INPUT</strong> I failed with the following approaches:</p>
  
  <pre><code># all lines also tested without .text suffix
      text1 = driver.find_element_by_class_name("display-table-cell.b-text_copy-2.
                                                b-text_weight-bold").text
      text2 = driver.find_element_by_class_name("warn").text 
      text3 = driver.find_element_by_class_name("col.xs12").text
      text4 = driver.find_element_by_class_name("display-table-cell").text
      text5 = driver.find_element_by_xpath("//*[contains(@text='I NEED THIS TEXT')]")
  </code></pre>
  
  <p><strong>OUTPUT</strong>:</p>
  
  <pre><code>text1: Message: Unable to locate element: .display-table-cell.b-text_copy-2.b-text_weight-bold
  text2: Message: Unable to locate element: .warn
  text3: Message: Unable to locate element: .col.xs12
  text4: Message: Unable to locate element: .display-table-cell
  text5: Message: Given xpath expression "//*[contains(@text='I NEED THIS TEXT')]" is invalid: [Exception... "&lt;no message&gt;"  nsresult: "0x8060000d (&lt;unknown&gt;)"  location: "JS frame :: chrome://marionette/content/element.js :: element.findByXPath :: line 355"  data: no]
  </code></pre>
  
  <p><strong>Am I doing something fundamentally wrong? How to select I NEED THIS TEXT and print it to console?</strong></p>