void CalendarRegressionTest::test4118384()
{
    UErrorCode status = U_ZERO_ERROR;
    Calendar *cal = Calendar::createInstance(status);
    if(U_FAILURE(status)) {
      dataerrln("Error creating calendar %s", u_errorName(status));
      delete cal;
      return;
    }
    if (cal->getMaximum(UCAL_HOUR) != 11 ||
        cal->getLeastMaximum(UCAL_HOUR) != 11 ||
        cal->getActualMaximum(UCAL_HOUR,status) != 11)
        errln("Fail: maximum of HOUR field should be 11");

    // test deprecated functions
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: [deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: [deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
    cal = Calendar::createInstance(Locale("th_TH@calendar=buddhist"),status);
    // test deprecated functions
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: Buddhist:[deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: Buddhist:[deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
    // test deprecated functions
    cal = Calendar::createInstance(Locale("ja_JP@calendar=japanese"),status);
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: Japanese:[deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: Japanese:[deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
}
void CalendarRegressionTest::test4118384()
{
    UErrorCode status = U_ZERO_ERROR;
    Calendar *cal = Calendar::createInstance(status);
    if(U_FAILURE(status)) {
      dataerrln("Error creating calendar %s", u_errorName(status));
      delete cal;
      return;
    }
    if (cal->getMaximum(UCAL_HOUR) != 11 ||
        cal->getLeastMaximum(UCAL_HOUR) != 11 ||
        cal->getActualMaximum(UCAL_HOUR,status) != 11)
        errln("Fail: maximum of HOUR field should be 11");

     
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: [deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: [deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
    cal = Calendar::createInstance(Locale("th_TH@calendar=buddhist"),status);
     
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: Buddhist:[deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: Buddhist:[deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
     
    cal = Calendar::createInstance(Locale("ja_JP@calendar=japanese"),status);
    if (cal->getLeastMaximum(Calendar::HOUR) != 11 ||
        cal->getMaximum(Calendar::HOUR) != 11) {
        errln("Fail: Japanese:[deprecated functions] maximum of HOUR field should be 11\n");
    }

    if (cal->getGreatestMinimum(Calendar::HOUR) != 0 ||
        cal->getMinimum(Calendar::HOUR) != 0) {
        errln("Fail: Japanese:[deprecated functions] minimum of HOUR field should be 1\n");
    }

    delete cal;
}