add setter into test
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6971 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
ffa8942be1
commit
995034cd2f
2 changed files with 11 additions and 5 deletions
|
|
@ -28,10 +28,6 @@ public class java_lib_various_runme {
|
|||
if ( !got[i].equals(expected[i]) )
|
||||
throw new RuntimeException("Name failed " + i + " " + got[i] + "|" + expected[i]);
|
||||
|
||||
// STRING_ARRAY variable setter
|
||||
// String newLangs[] = { "French", "Italian", "Spanish" };
|
||||
// java_lib_various.setLanguages(newLangs);
|
||||
|
||||
// STRING_ARRAY variable getter
|
||||
String langscheck[] = { "Hungarian", "Afrikaans", "Norwegian" };
|
||||
String langs[] = java_lib_various.getLanguages();
|
||||
|
|
@ -39,6 +35,16 @@ public class java_lib_various_runme {
|
|||
if ( !langs[i].equals(langscheck[i]) )
|
||||
throw new RuntimeException("Languages read failed " + i + " " + langs[i] + "|" + langscheck[i]);
|
||||
|
||||
// STRING_ARRAY variable setter
|
||||
String newLangs[] = { "French", "Italian", "Spanish" };
|
||||
java_lib_various.setLanguages(newLangs);
|
||||
|
||||
// STRING_ARRAY variable getter
|
||||
langs = java_lib_various.getLanguages();
|
||||
for (int i=0; i<langs.length; i++)
|
||||
if ( !langs[i].equals(newLangs[i]) )
|
||||
throw new RuntimeException("Languages verify failed " + i + " " + langs[i] + "|" + newLangs[i]);
|
||||
|
||||
// STRING_RET test
|
||||
{
|
||||
String stringOutArray[] = { "" };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue