1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110
|
// =============================================================================
// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
// Copyright (C) 2010 - DIGITEO - Allan CORNET
//
// This file is distributed under the same license as the Scilab package.
// =============================================================================
// <-- JVM NOT MANDATORY -->
// <-- Non-regression test for bug 7278 -->
//
// <-- Bugzilla URL -->
// http://bugzilla.scilab.org/show_bug.cgi?id=7278
//
// <-- Short Description -->
// strsplit did not work with some particular inputs.
//===============================
if strsplit("0") <> "0" then bugmes();quit;end
//===============================
if strsplit("0","") <> "0" then bugmes();quit;end
if strsplit("1","") <> "1" then bugmes();quit;end
if strsplit("2","") <> "2" then bugmes();quit;end
if strsplit("3","") <> "3" then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",":",1);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",":",1);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",",");
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("","/:|,/");
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("","/:|,/");
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","]);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","]);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","]);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","],2);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","],2);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("",[":";","],2);
if r_1 <> "" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("r",":",1);
if r_1 <> "r" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(":",":",1);
if r_1 <> ":" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(",",",");
if r_1 <> "," then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("r","/:|,/");
if r_1 <> "r" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(":","/:|,/");
if r_1 <> ":" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("a",[":";","]);
if r_1 <> "a" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(":",[":";","]);
if r_1 <> ":" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(",",[":";","]);
if r_1 <> "," then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit("a",[":";","],2);
if r_1 <> "a" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(":",[":";","],2);
if r_1 <> ":" then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
[r_1, r_2] = strsplit(",",[":";","],2);
if r_1 <> "," then bugmes();quit;end
if r_2 <> [] then bugmes();quit;end
//===============================
|