Class DataPackRegistriesTest
java.lang.Object
net.neoforged.neoforge.oldtest.misc.DataPackRegistriesTest
This test class shows an example of how to register unsynced and synced datapack registries, and how to use a dataprovider to generate json files for them. It also verifies that data and tags are loaded and synced correctly. Data is loaded from the following folders in test resources:
data/data_pack_registries_test/data_pack_registries_test/unsyncable/test.json
data/data_pack_registries_test/tags/data_pack_registries_test/unsyncable/test.json
data/data_pack_registries_test/data_pack_registries_test/syncable/test.json
data/data_pack_registries_test/tags/data_pack_registries_test/syncable/test.json
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static class
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final boolean
private static final org.slf4j.Logger
static final String
private static final ResourceLocation
-
Constructor Summary
-
Method Summary
-
Field Details
-
ENABLED
private static final boolean ENABLED- See Also:
-
MODID
- See Also:
-
LOGGER
private static final org.slf4j.Logger LOGGER -
TEST_RL
-
datagenTestObject
private final DeferredHolder<DataPackRegistriesTest.Unsyncable,DataPackRegistriesTest.Unsyncable> datagenTestObject
-
-
Constructor Details
-
DataPackRegistriesTest
public DataPackRegistriesTest(net.neoforged.bus.api.IEventBus modBus)
-
-
Method Details
-
onGatherData
-
onServerStarting
-