fix: conf for etherdream uses ip
This commit is contained in:
parent
ee4d0e049f
commit
ffba2efeed
@ -30,7 +30,7 @@ pub struct HeliosConf {
|
|||||||
|
|
||||||
#[derive(Serialize, Deserialize, Debug, Clone)]
|
#[derive(Serialize, Deserialize, Debug, Clone)]
|
||||||
pub struct EtherDreamConf {
|
pub struct EtherDreamConf {
|
||||||
pub url: String
|
pub ip: String
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Serialize, Deserialize, Debug, Clone)]
|
#[derive(Serialize, Deserialize, Debug, Clone)]
|
||||||
|
@ -12,4 +12,4 @@ redis_url = "redis://127.0.0.1:6379/"
|
|||||||
|
|
||||||
# For Etherdream. IP of the DAC
|
# For Etherdream. IP of the DAC
|
||||||
[dac.etherdream]
|
[dac.etherdream]
|
||||||
url = "192.168.1.68"
|
ip = "192.168.1.68"
|
||||||
|
@ -28,7 +28,7 @@ fn it_finds_struct_fields() {
|
|||||||
fn it_finds_etherdream_fields() {
|
fn it_finds_etherdream_fields() {
|
||||||
let config = Conf::new("tests/settings/valid_etherdream").unwrap();
|
let config = Conf::new("tests/settings/valid_etherdream").unwrap();
|
||||||
assert!(match config.dac {
|
assert!(match config.dac {
|
||||||
DacFamily::Etherdream(EtherDreamConf { url }) if url == "192.168.1.68" => true,
|
DacFamily::Etherdream(EtherDreamConf { ip }) if ip == "192.168.1.68" => true,
|
||||||
_ => false,
|
_ => false,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user