use of tech.pegasys.teku.config.TekuConfiguration in project teku by ConsenSys.
the class ValidatorOptionsTest method shouldReportEmptyIfFeeRecipientNotSpecified.
@Test
public void shouldReportEmptyIfFeeRecipientNotSpecified() {
final TekuConfiguration config = getTekuConfigurationFromArguments();
assertThat(config.validatorClient().getValidatorConfig().getProposerDefaultFeeRecipient()).isEmpty();
}
use of tech.pegasys.teku.config.TekuConfiguration in project teku by ConsenSys.
the class ValidatorOptionsTest method shouldEnableBlindedBeaconBlocks.
@Test
public void shouldEnableBlindedBeaconBlocks() {
final String[] args = { "--Xvalidators-blinded-blocks-api-enabled", "true" };
final TekuConfiguration config = getTekuConfigurationFromArguments(args);
assertThat(config.validatorClient().getValidatorConfig().isBlindedBeaconBlocksApiEnabled()).isTrue();
}
use of tech.pegasys.teku.config.TekuConfiguration in project teku by ConsenSys.
the class ValidatorOptionsTest method beaconNodeApiEndpoint_shouldBeEmptyByDefault.
@Test
void beaconNodeApiEndpoint_shouldBeEmptyByDefault() {
TekuConfiguration tekuConfiguration = getTekuConfigurationFromArguments();
assertThat(tekuConfiguration.validatorClient().getValidatorConfig().getBeaconNodeApiEndpoint()).isEmpty();
}
use of tech.pegasys.teku.config.TekuConfiguration in project teku by ConsenSys.
the class Eth2NetworkOptionsTest method shouldLoadMergeTerminalBlockHashOverride.
@Test
void shouldLoadMergeTerminalBlockHashOverride() {
final TekuConfiguration config = getTekuConfigurationFromArguments("--Xnetwork-terminal-block-hash-override", "0x7562f205a2d14e80a3a67da9df0b769b0ba0111a8e81034606f8f27f51f4dd8e");
assertThat(config.eth2NetworkConfiguration().getTerminalBlockHashOverride()).isEqualTo(Optional.of(Bytes32.fromHexStringStrict("0x7562f205a2d14e80a3a67da9df0b769b0ba0111a8e81034606f8f27f51f4dd8e")));
assertThat(createConfigBuilder().eth2NetworkConfig(b -> b.terminalBlockHashOverride(Bytes32.fromHexStringStrict("0x7562f205a2d14e80a3a67da9df0b769b0ba0111a8e81034606f8f27f51f4dd8e"))).build()).usingRecursiveComparison().isEqualTo(config);
}
use of tech.pegasys.teku.config.TekuConfiguration in project teku by ConsenSys.
the class Eth2NetworkOptionsTest method shouldUseBellatrixForkEpochIfSpecified.
@Test
void shouldUseBellatrixForkEpochIfSpecified() {
final TekuConfiguration config = getTekuConfigurationFromArguments("--Xnetwork-bellatrix-fork-epoch", "120000", "--Xee-endpoint", "someEndpoint");
final Spec spec = config.eth2NetworkConfiguration().getSpec();
assertThat(spec.getForkSchedule().getSpecMilestoneAtEpoch(UInt64.valueOf(119999))).isEqualTo(SpecMilestone.ALTAIR);
assertThat(spec.getForkSchedule().getSpecMilestoneAtEpoch(UInt64.valueOf(120000))).isEqualTo(SpecMilestone.BELLATRIX);
assertThat(createConfigBuilder().executionEngine(b -> b.endpoint("someEndpoint")).eth2NetworkConfig(b -> b.bellatrixForkEpoch(UInt64.valueOf(120000))).build()).usingRecursiveComparison().isEqualTo(config);
}
Aggregations