diff options
Diffstat (limited to 'ecomp-sdk')
-rw-r--r-- | ecomp-sdk/epsdk-analytics/src/test/java/org/onap/portalsdk/analytics/view/RowHeaderColTest.java | 63 |
1 files changed, 36 insertions, 27 deletions
diff --git a/ecomp-sdk/epsdk-analytics/src/test/java/org/onap/portalsdk/analytics/view/RowHeaderColTest.java b/ecomp-sdk/epsdk-analytics/src/test/java/org/onap/portalsdk/analytics/view/RowHeaderColTest.java index 180abf02..932a4e75 100644 --- a/ecomp-sdk/epsdk-analytics/src/test/java/org/onap/portalsdk/analytics/view/RowHeaderColTest.java +++ b/ecomp-sdk/epsdk-analytics/src/test/java/org/onap/portalsdk/analytics/view/RowHeaderColTest.java @@ -4,6 +4,8 @@ * =================================================================== * Copyright © 2017 AT&T Intellectual Property. All rights reserved. * =================================================================== + * Modifications Copyright © 2018 IBM. + * =================================================================== * * Unless otherwise specified, all software contained herein is licensed * under the Apache License, Version 2.0 (the "License"); @@ -35,6 +37,7 @@ * * */ + package org.onap.portalsdk.analytics.view; import static org.junit.Assert.*; @@ -43,33 +46,39 @@ import org.junit.Test; public class RowHeaderColTest { - @Test - public void mockRowHeaderColTest() { - RowHeaderCol rowHeaderCol = new RowHeaderCol(); - rowHeaderCol.setColumnTitle("columnTitle"); - rowHeaderCol.setColumnWidth("columnWidth"); - rowHeaderCol.setAlignment("alignment"); - rowHeaderCol.setColId("colId"); - rowHeaderCol.setDisplayHeaderAlignment(null); - assertNull(rowHeaderCol.getDisplayHeaderAlignment()); - assertEquals(rowHeaderCol.getColId(), "colId"); - assertEquals(rowHeaderCol.getColumnTitle(), "columnTitle"); - assertEquals(rowHeaderCol.getColumnWidth(), "columnWidth"); - assertEquals(rowHeaderCol.getAlignment(), "alignment"); - assertEquals(rowHeaderCol.getColumnTitleHtml(), "columnTitle"); - assertEquals(rowHeaderCol.getColumnWidthHtml(), " width=columnWidth"); - assertEquals(rowHeaderCol.getAlignmentHtml(), " align=alignment"); - rowHeaderCol.resetNext(); - RowHeader rowHeader = new RowHeader(); - rowHeaderCol.addRowHeader(rowHeader); - rowHeaderCol.addRowHeader(1, rowHeader); - rowHeaderCol.setColumnTitle(""); - rowHeaderCol.setColumnWidth(""); - rowHeaderCol.setAlignment(""); - assertEquals(rowHeaderCol.getColumnTitleHtml(), " "); - assertEquals(rowHeaderCol.getColumnWidthHtml(), ""); - assertEquals(rowHeaderCol.getAlignmentHtml(), " align=center"); + @Test + public void mockRowHeaderColTest() { + RowHeaderCol rowHeaderCol = new RowHeaderCol(); + rowHeaderCol.setColumnTitle("columnTitle"); + rowHeaderCol.setColumnWidth("columnWidth"); + rowHeaderCol.setAlignment("alignment"); + rowHeaderCol.setColId("colId"); + rowHeaderCol.setDisplayHeaderAlignment(null); + rowHeaderCol.setNowrap("noWrap"); + rowHeaderCol.setVisible(true); + assertEquals("noWrap", rowHeaderCol.getNowrap()); + assertEquals(true, rowHeaderCol.isVisible()); + assertNull(rowHeaderCol.getDisplayHeaderAlignment()); + assertEquals(rowHeaderCol.getColId(), "colId"); + assertEquals(rowHeaderCol.getColumnTitle(), "columnTitle"); + assertEquals(rowHeaderCol.getColumnWidth(), "columnWidth"); + assertEquals(rowHeaderCol.getAlignment(), "alignment"); + assertEquals(rowHeaderCol.getColumnTitleHtml(), "columnTitle"); + assertEquals(rowHeaderCol.getColumnWidthHtml(), " width=columnWidth"); + assertEquals(rowHeaderCol.getAlignmentHtml(), " align=alignment"); + rowHeaderCol.resetNext(); + RowHeader rowHeader = new RowHeader(); + rowHeaderCol.addRowHeader(rowHeader); + rowHeaderCol.addRowHeader(1, rowHeader); + rowHeaderCol.setColumnTitle(""); + rowHeaderCol.setColumnWidth(""); + rowHeaderCol.setAlignment(""); + assertTrue(rowHeaderCol.hasNext()); + assertNotNull(rowHeaderCol.getNext()); + assertEquals(rowHeaderCol.getColumnTitleHtml(), " "); + assertEquals(rowHeaderCol.getColumnWidthHtml(), ""); + assertEquals(rowHeaderCol.getAlignmentHtml(), " align=center"); - } + } } |