Skip to content

Commit

Permalink
ci: change some test codes
Browse files Browse the repository at this point in the history
  • Loading branch information
hizumiaoba committed Dec 13, 2021
1 parent 5527ff3 commit c5ddabb
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 11 deletions.
18 changes: 16 additions & 2 deletions generated/database.json
Original file line number Diff line number Diff line change
Expand Up @@ -13729,10 +13729,10 @@
}, {
"attribute" : "キュート",
"name" : "Secret Mirage",
"difficulty" : "MASTER+",
"difficulty" : "ⓁMASTER+",
"level" : 28,
"notes" : 757,
"albumType" : "Not-implemented"
"albumType" : "ALBUM A"
}, {
"attribute" : "キュート",
"name" : "とんでいっちゃいたいの",
Expand Down Expand Up @@ -14503,5 +14503,19 @@
"level" : 27,
"notes" : 500,
"albumType" : "Not-implemented"
}, {
"attribute" : "キュート",
"name" : "Secret Mirage",
"difficulty" : "MASTER+",
"level" : 28,
"notes" : 759,
"albumType" : "ALBUM A"
}, {
"attribute" : "全タイプ",
"name" : "Shine!!",
"difficulty" : "MASTER+",
"level" : 30,
"notes" : 977,
"albumType" : "ALBUM A"
} ]
}
3 changes: 2 additions & 1 deletion src/com/ranfa/languages/List_en_US.properties
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
MSGCalcStart:Start!
MSGCalcStart:Start!
MSGDatabaseNotExist:Music database does not exist.\nIt will be automatically created.\nATTENTION:There is the JSON file named \"database.json\" in the same directory which executable is contained and you see this pop up,\nPlease contact the Developer.\nGithub URL: https://github.com/hizumiaoba/DelesteRandomSelector/issues
3 changes: 2 additions & 1 deletion src/com/ranfa/languages/List_ja_JP.properties
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
MSGCalcStart:\u958b\u59cb\uff01
MSGCalcStart:\u958b\u59cb\uff01
MSGDatabaseNotExist:\u697d\u66f2\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3067\u3057\u305f\u3002\u81ea\u52d5\u7684\u306b\u4f5c\u6210\u3055\u308c\u307e\u3059\u2026\n\u6ce8\u610f\uff1a\u521d\u56de\u8d77\u52d5\u3067\u306f\u306a\u304f\u3001\u304b\u3064\u3001Jar\u30d5\u30a1\u30a4\u30eb\u3068\u540c\u3058\u968e\u5c64\u306b\"database.json\"\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u304c\u5b58\u5728\u3059\u308b\u306b\u3082\u95a2\u308f\u3089\u305a\n\u3053\u306e\u30dd\u30c3\u30d7\u30a2\u30c3\u30d7\u304c\u51fa\u305f\u5834\u5408\u3001\u958b\u767a\u8005\u307e\u3067\u3054\u4e00\u5831\u304f\u3060\u3055\u3044\u3002\nGithub URL: https://github.com/hizumiaoba/DelesteRandomSelector/issues
3 changes: 2 additions & 1 deletion src/com/ranfa/main/Messages.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
*/
public enum Messages {

MSGCalcStart;
MSGCalcStart,
MSGDatabaseNotExist;

@Override
public String toString() {
Expand Down
12 changes: 6 additions & 6 deletions src/test/LanguageTest.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package test;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;

import java.util.Locale;

Expand All @@ -19,24 +19,24 @@ public class LanguageTest {
@Test
public void jpTest() {
// Set locale
Locale.setDefault(jp);
Locale.setDefault(this.jp);

// asserts
assertEquals("開始!", Messages.MSGCalcStart.toString());
assertTrue(Messages.MSGCalcStart.toString().equals("開始!"));
}

@Test
public void enTest() {
//set locale
Locale.setDefault(us);
Locale.setDefault(this.us);

// asserts
assertEquals("Start!", Messages.MSGCalcStart.toString());
assertTrue(Messages.MSGCalcStart.toString().equals("Start!"));
}

@After
public void revertDefault() {
Locale.setDefault(defaultLocale);
Locale.setDefault(this.defaultLocale);
}

}

0 comments on commit c5ddabb

Please sign in to comment.