9
0
mirror of https://github.com/WiIIiam278/HuskSync.git synced 2025-12-26 01:59:20 +00:00

Fix tests, create DummySettings

This commit is contained in:
William
2022-08-08 19:44:12 +01:00
parent 2f700b2d93
commit 593c88c8ba
5 changed files with 34 additions and 13 deletions

View File

@@ -4,10 +4,7 @@ import dev.dejvokep.boostedyaml.YamlDocument;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.*;
/**
* Settings used for the plugin, as read from the config file
@@ -17,7 +14,7 @@ public class Settings {
/**
* Map of {@link ConfigOption}s read from the config file
*/
private final HashMap<ConfigOption, Object> configOptions;
private final Map<ConfigOption, Object> configOptions;
// Load the settings from the document
private Settings(@NotNull YamlDocument config) {
@@ -33,6 +30,11 @@ public class Settings {
}));
}
// Default constructor for empty settings
protected Settings(@NotNull Map<ConfigOption, Object> configOptions) {
this.configOptions = configOptions;
}
/**
* Get the value of the specified {@link ConfigOption}
*