Answered Questions

  • Explain White box testing related to Java ?

    ABHISHEK MISHRA

    • Oct 5th, 2014

    White box testing is the detailed investigation of internal logic and structure of the code. White box testing is also called glass testing or open box testing. In order to perform white box testing o...

  • Java code to set column width in CSV file

    Can someone help on how to set the column width in CSV file using javacode. I have used FileWriter class to upload data into the csv file. Results are getting populated properly but csv file showing results with default column width. Is there a way we can set the width of the column dynamically based on result length or set fixed length?

    Dusmanta

    • Nov 12th, 2014

    Use Apachae POI jar for this HSSFSheet sheet = workBook.createSheet("testXls");

    Code
    1. // Code to Auto size the column widths
    2.         for(int columnPosition = 0; columnPosition< 5; columnPosition++) {
    3.              sheet.autoSizeColumn((short) (columnPosition));
    4.         }

  • JUnit

    What is JUnit and how it is used?

    Satendra Kumar

    • Nov 10th, 2014

    JUnit is primary testing which is done by programmer to ensure that my code is a quality code.
    we can used unit testing by creating test cases ........