forked from nus-cs2103-AY2425S1/tp
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sample data consistent with command behavior
- Loading branch information
Showing
3 changed files
with
11 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,7 +27,7 @@ | |
public class SampleDataUtil { | ||
public static Person[] getSamplePersons() { | ||
Game sampleGame = new Game("LoL", | ||
new Username("LeagueGamer"), new SkillLevel("bad"), new Role("Support"), false); | ||
new Username("LeagueGamer"), new SkillLevel("Diamond"), new Role("Support"), false); | ||
HashMap<String, Game> sample = new HashMap<String, Game>(); | ||
sample.put("LoL", sampleGame); | ||
return new Person[] { | ||
|
@@ -37,23 +37,23 @@ public static Person[] getSamplePersons() { | |
getPreferredTimeSet("2100-2200")), | ||
new Person(new Name("Bernice Yu"), new Phone("99272758"), new Email("[email protected]"), | ||
new Address("Blk 30 Lorong 3 Serangoon Gardens, #07-18"), | ||
getTagSet("colleagues", "friends"), getGameMap("LoL"), | ||
getTagSet("colleagues", "friends"), getGameMap("LoL", "Overwatch"), | ||
getPreferredTimeSet("2030-2130")), | ||
new Person(new Name("Charlotte Oliveiro"), new Phone("93210283"), new Email("[email protected]"), | ||
new Address("Blk 11 Ang Mo Kio Street 74, #11-04"), | ||
getTagSet("neighbours"), getGameMap("LoL"), | ||
getTagSet("neighbours"), getGameMap("DOTA2"), | ||
getPreferredTimeSet("1900-2100")), | ||
new Person(new Name("David Li"), new Phone("91031282"), new Email("[email protected]"), | ||
new Address("Blk 436 Serangoon Gardens Street 26, #16-43"), | ||
getTagSet("family"), getGameMap("LoL"), | ||
getTagSet("family"), getGameMap("Genshin Impact"), | ||
getPreferredTimeSet("2100-2130", "1900-2030")), | ||
new Person(new Name("Irfan Ibrahim"), new Phone("92492021"), new Email("[email protected]"), | ||
new Address("Blk 47 Tampines Street 20, #17-35"), | ||
getTagSet("classmates"), getGameMap("LoL"), | ||
getTagSet("classmates"), getGameMap("Honkai Star Rail"), | ||
getPreferredTimeSet("1800-2000")), | ||
new Person(new Name("Roy Balakrishnan"), new Phone("92624417"), new Email("[email protected]"), | ||
new Address("Blk 45 Aljunied Street 85, #11-31"), | ||
getTagSet("colleagues"), getGameMap("LoL"), | ||
getTagSet("colleagues"), getGameMap("Honkai Star Rail"), | ||
getPreferredTimeSet("2100-2130")) | ||
}; | ||
} | ||
|
@@ -81,8 +81,7 @@ public static Set<Tag> getTagSet(String... strings) { | |
public static Map<String, Game> getGameMap(String... strings) { | ||
Map<String, Game> gameMap = new HashMap<>(); | ||
Arrays.stream(strings) | ||
.forEach((gameName) -> gameMap.put(gameName, new Game(gameName, new Username("nil"), | ||
new SkillLevel("nil"), new Role("nil"), false))); | ||
.forEach((gameName) -> gameMap.put(gameName, new Game(gameName))); | ||
return gameMap; | ||
} | ||
|
||
|