title: How to create a HTML report for pytest?
body: <p>I have created a project in eclipse using pytest framework</p>
  
  <pre><code>class TestClass(object):
      def test_one(self):
          x = "this"
          assert 'h' in x
  
      def test_two(self):
          x = "hello"
          assert hasattr(x, 'check')
  </code></pre>
  
  <p>Now, I want to create a html report for my project.I have done the following:</p>
  
  <ul>
  <li>Installed the html plugin </li>
  <li>Written the below code in conftest.py module</li>
  </ul>
  
  <blockquote>
  <pre><code>import pytest
  
  @pytest.mark.hookwrapper
  def pytest_runtest_makereport(item, call):
      pytest_html = item.config.pluginmanager.getplugin('html')
      outcome = yield
      report = outcome.get_result()
  </code></pre>
  </blockquote>
  
  <p>When I ran my test, I didn't get any report.Below is my result as expected, but no report got generated</p>
  
  <pre><code>&gt; ============================= test session starts ============================= platform win32 -- Python 3.6.5, pytest-3.6.0, py-1.5.3, pluggy-0.6.0 rootdir: D:\Eclipse1\TFCProject,
  &gt; inifile: plugins: ordering-0.5, metadata-1.7.0, html-1.19.0 collected
  &gt; 2 items
  &gt; 
  &gt; TFCPackage\pycheck.py .F                                              
  &gt; [100%]
  &gt; 
  &gt; ================================== FAILURES ===================================
  &gt; _____________________________ TestClass.test_two self = &lt;TFCPackage.pycheck.TestClass object at 0x03778AF0&gt;
  
      def test_two(self):
          x = "hello"
  &gt;       assert hasattr(x, 'check')
  E       AssertionError: assert False
  E        +  where False = hasattr('hello', 'check')
  
  TFCPackage\pycheck.py:13: AssertionError
  ===================== 1 failed, 1 passed in 0.41 seconds ======================
  </code></pre>
  
  <p>Please guide me as I am new to pytest</p>