Examples of HTMLSupport


Examples of org.jacoco.report.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    column = new BarColumn(CounterEntity.LINE, Locale.ENGLISH);
  }
View Full Code Here

Examples of org.jacoco.report.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    locale = Locale.ENGLISH;
  }
View Full Code Here

Examples of org.jacoco.report.html.HTMLSupport

        new StubRenderer(CounterComparator.TOTALITEMS.reverse().on(
            CounterEntity.CLASS)), false);
    table.render(body, items, createTotal("Sum", 6), resources, root);
    doc.close();

    final HTMLSupport support = new HTMLSupport();
    final Document doc = support.parse(output.getFile("Test.html"));

    // The elements in Column 1 are sorted in forward order:
    assertEquals("sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@class"));
    assertEquals("a",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@id"));
    assertEquals("a2",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[1]/@id"));
    assertEquals("a3",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[1]/@id"));
    assertEquals("a0",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[1]/@id"));
    assertEquals("a1",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[1]/@id"));

    // The elements in Column 2 are sorted in reverse order:
    assertEquals("sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[2]/@class"));
    assertEquals("b",
        support.findStr(doc, "/html/body/table/thead/tr/td[2]/@id"));
    assertEquals("b1",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[2]/@id"));
    assertEquals("b0",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[2]/@id"));
    assertEquals("b3",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[2]/@id"));
    assertEquals("b2",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[2]/@id"));
  }
View Full Code Here

Examples of org.jacoco.report.html.HTMLSupport

    table.add("Forward", null, new StubRenderer(
        CounterComparator.TOTALITEMS.on(CounterEntity.CLASS)), true);
    table.render(body, items, createTotal("Sum", 1), resources, root);
    doc.close();

    final HTMLSupport support = new HTMLSupport();
    final Document doc = support.parse(output.getFile("Test.html"));

    assertEquals("down sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@class"));
    assertEquals("A",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[1]"));
    assertEquals("B",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[1]"));
    assertEquals("C",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[1]"));
    assertEquals("D",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[1]"));
    assertEquals("E",
        support.findStr(doc, "/html/body/table/tbody/tr[5]/td[1]"));
  }
View Full Code Here

Examples of org.jacoco.report.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    column = new LabelColumn();
  }
View Full Code Here

Examples of org.jacoco.report.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    column = new PercentageColumn(CounterEntity.LINE, Locale.ENGLISH);
  }
View Full Code Here

Examples of org.jacoco.report.internal.html.HTMLSupport

        new StubRenderer(CounterComparator.TOTALITEMS.reverse().on(
            CounterEntity.CLASS)), false);
    table.render(body, items, createTotal("Sum", 6), resources, root);
    doc.close();

    final HTMLSupport support = new HTMLSupport();
    final Document doc = support.parse(output.getFile("Test.html"));

    // The elements in Column 1 are sorted in forward order:
    assertEquals("sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@class"));
    assertEquals("a",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@id"));
    assertEquals("a2",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[1]/@id"));
    assertEquals("a3",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[1]/@id"));
    assertEquals("a0",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[1]/@id"));
    assertEquals("a1",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[1]/@id"));

    // The elements in Column 2 are sorted in reverse order:
    assertEquals("sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[2]/@class"));
    assertEquals("b",
        support.findStr(doc, "/html/body/table/thead/tr/td[2]/@id"));
    assertEquals("b1",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[2]/@id"));
    assertEquals("b0",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[2]/@id"));
    assertEquals("b3",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[2]/@id"));
    assertEquals("b2",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[2]/@id"));
  }
View Full Code Here

Examples of org.jacoco.report.internal.html.HTMLSupport

    table.add("Forward", null, new StubRenderer(
        CounterComparator.TOTALITEMS.on(CounterEntity.CLASS)), true);
    table.render(body, items, createTotal("Sum", 1), resources, root);
    doc.close();

    final HTMLSupport support = new HTMLSupport();
    final Document doc = support.parse(output.getFile("Test.html"));

    assertEquals("down sortable",
        support.findStr(doc, "/html/body/table/thead/tr/td[1]/@class"));
    assertEquals("A",
        support.findStr(doc, "/html/body/table/tbody/tr[1]/td[1]"));
    assertEquals("B",
        support.findStr(doc, "/html/body/table/tbody/tr[2]/td[1]"));
    assertEquals("C",
        support.findStr(doc, "/html/body/table/tbody/tr[3]/td[1]"));
    assertEquals("D",
        support.findStr(doc, "/html/body/table/tbody/tr[4]/td[1]"));
    assertEquals("E",
        support.findStr(doc, "/html/body/table/tbody/tr[5]/td[1]"));
  }
View Full Code Here

Examples of org.jacoco.report.internal.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    column = new LabelColumn();
  }
View Full Code Here

Examples of org.jacoco.report.internal.html.HTMLSupport

    root = new ReportOutputFolder(output);
    resources = new Resources(root);
    doc = new HTMLDocument(root.createFile("Test.html"), "UTF-8");
    doc.head().title();
    td = doc.body().table("somestyle").tr().td();
    support = new HTMLSupport();
    column = new PercentageColumn(CounterEntity.LINE, Locale.ENGLISH);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.