Author: lfryc(a)redhat.com
Date: 2010-11-01 11:31:37 -0400 (Mon, 01 Nov 2010)
New Revision: 19841
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richDataGrid/AbstractDataGridTest.java
Log:
rich:dataGrid - fixed the tests for expected number of columns (should be equal to
@columns or zero in case that no more elements are available in model)
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richDataGrid/AbstractDataGridTest.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richDataGrid/AbstractDataGridTest.java 2010-11-01
15:25:46 UTC (rev 19840)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richDataGrid/AbstractDataGridTest.java 2010-11-01
15:31:37 UTC (rev 19841)
@@ -158,7 +158,11 @@
}
expectedRows = ceil((float) expectedElements / columns);
- expectedColumns = Math.min(columns, expectedElements);
+ expectedColumns = columns;
+
+ if (first >= ELEMENTS_TOTAL) {
+ expectedColumns = 0;
+ }
}
private Iterator<Capital> getExpectedCapitalsIterator() {
Show replies by date