/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/* @test
* @bug 4712786
* @summary Check charsets against reference files
*
* @build Util
* @run main Check shift_jis ref.shift_jis
* @run main/othervm -Dsun.nio.cs.map=Windows-31J/Shift_JIS Check shift_jis ref.windows-31j
*/
public class Check {
}
throws IOException
{
while (m.find()) {
for (int i = 0; i < nb; i++) {
16);
}
}
return this;
}
private void error() {
if (++errors >= 100)
throw new RuntimeException("100 errors occurred (there might be more)");
}
+ "\": Expected {"
+ "}, got {"
+ "}");
error();
}
+ "\", input {"
+ "}: Expected \""
+ "\", got \""
+ "\"");
error();
}
private void check()
throws IOException
{
// String.getBytes(String csn)
for (int i = 0; i < UNICODE_SIZE; i++) {
continue;
}
// String(byte[] ba, String csn)
for (int i = 0; i < UNICODE_SIZE; i++) {
continue;
if (!r.equals(s))
}
// To be really thorough we should test OutputStreamWriter,
// InputStreamReader, and Charset{De,En}Coder here also,
// but the above will do for now.
if (errors > 0) {
}
}
// Usage: Check charsetName referenceFileName
}
}