hunk.code_window:         self.assertEqual(mail.reply_to, self.company_admin.partner_id.email_formatted)
           self.assertEqual(mail.state, 'outgoing')
           # test body content: KPIs
           body_html = html.fromstring(mail.body_html)
           kpi_values = body_html.xpath('//div[@data-field="mail"]//*[hasclass("kpi_value")]/text()')
           self.assertEqual(
               [t.strip().strip('%') for t in kpi_values],
               ['100', str(mailing.opened_ratio), str(mailing.replied_ratio)]
           )
           # test body content: clicks (a bit hackish but hey we are in stable)
  
hunk.labels: keep keep keep keep replace keep keep keep keep keep
hunk.after_edit:         kpi_values = body_html.xpath('//table[@data-field="mail"]//*[hasclass("kpi_value")]/text()')
  
hunk.file_path: addons/test_mass_mailing/tests/test_mailing_statistics.py
hunk.type: replace
file: <?xml version="1.0" encoding="utf-8"?>
  <odoo>
  
      <record id="sale_order_form_view_inherit" model="ir.ui.view">
          <field name="name">sale.order.form.inherit.sale.expense</field>
          <field name="model">sale.order</field>
          <field name="inherit_id" ref="sale.view_order_form"/>
          <field name="arch" type="xml">
              <data>
                 <xpath expr="//button[@name='action_view_invoice']" position="before">
                     <button type="action"
                         name="%(sale_expense.hr_expense_action_from_sale_order)d"
                         class="oe_stat_button"
                         icon="fa-money"
                         attrs="{'invisible': [('expense_count', '=', 0)]}">
                         <field name="expense_count" widget="statinfo" string="Expenses"/>
                     </button>
                  </xpath>
              </data>
          </field>
      </record>
  
  </odoo>
  