Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solar position pull-request #104

Merged
merged 10 commits into from
Feb 27, 2024
342 changes: 169 additions & 173 deletions Cargo.lock

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions backends/drmem-db-simple/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ mod tests {
{
let data = vec![1, 2, 3];

f(device::Value::Int(data[0]));
f(device::Value::Int(data[0])).await;

let s = db
.monitor_device(name.clone(), None, None)
Expand All @@ -509,7 +509,7 @@ mod tests {
tokio::pin!(s);

for ii in &data[1..] {
f(device::Value::Int(*ii));
f(device::Value::Int(*ii)).await;
}

assert_eq!(
Expand All @@ -533,8 +533,8 @@ mod tests {
{
let data = vec![1, 2, 3, 4];

f(device::Value::Int(data[0]));
f(device::Value::Int(data[1]));
f(device::Value::Int(data[0])).await;
f(device::Value::Int(data[1])).await;

let s = db
.monitor_device(name.clone(), None, None)
Expand All @@ -545,7 +545,7 @@ mod tests {
tokio::pin!(s);

for ii in &data[2..] {
f(device::Value::Int(*ii));
f(device::Value::Int(*ii)).await;
}

assert_eq!(
Expand Down Expand Up @@ -597,7 +597,7 @@ mod tests {
assert!(s.try_next().await.is_err());

for ii in data {
f(device::Value::Int(ii));
f(device::Value::Int(ii)).await;
}

assert_eq!(
Expand All @@ -621,7 +621,7 @@ mod tests {
{
let data = vec![1, 2, 3];

f(device::Value::Int(data[0]));
f(device::Value::Int(data[0])).await;

let s = db
.monitor_device(
Expand All @@ -636,7 +636,7 @@ mod tests {
tokio::pin!(s);

for ii in &data[1..] {
f(device::Value::Int(*ii));
f(device::Value::Int(*ii)).await;
}

assert_eq!(
Expand Down Expand Up @@ -669,7 +669,7 @@ mod tests {
{
let data = vec![1, 2, 3];

f(device::Value::Int(data[0]));
f(device::Value::Int(data[0])).await;

let s = db
.monitor_device(
Expand All @@ -684,7 +684,7 @@ mod tests {
tokio::pin!(s);

for ii in &data[1..] {
f(device::Value::Int(*ii));
f(device::Value::Int(*ii)).await;
}

assert_eq!(
Expand Down Expand Up @@ -738,7 +738,7 @@ mod tests {

for ii in data {
interval.tick().await;
f(device::Value::Int(ii));
f(device::Value::Int(ii)).await;
}

assert_eq!(s.try_next().await.unwrap(), None);
Expand All @@ -750,7 +750,7 @@ mod tests {
{
let data = vec![1, 2, 3, 4, 5];

f(device::Value::Int(data[0]));
f(device::Value::Int(data[0])).await;
let mut interval = interval(time::Duration::from_millis(100));

let now = time::SystemTime::now();
Expand All @@ -772,7 +772,7 @@ mod tests {

for ii in &data[1..] {
interval.tick().await;
f(device::Value::Int(*ii));
f(device::Value::Int(*ii)).await;
}

assert_eq!(
Expand Down Expand Up @@ -817,7 +817,7 @@ mod tests {

for ii in data {
interval.tick().await;
f(device::Value::Int(ii));
f(device::Value::Int(ii)).await;
}

assert_eq!(
Expand Down Expand Up @@ -866,7 +866,7 @@ mod tests {

for ii in data {
interval.tick().await;
f(device::Value::Int(ii));
f(device::Value::Int(ii)).await;
}

assert_eq!(
Expand Down
2 changes: 1 addition & 1 deletion drmemd/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ tracing-subscriber = { workspace = true, features = ["ansi"] }
serde.workspace = true
serde_derive.workspace = true

clap = { version = "4", features = ["cargo"] }
clap = { version = "~4.4", features = ["cargo"] }

chrono = { workspace = true, features = ["clock"] }

Expand Down
4 changes: 2 additions & 2 deletions drmemd/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ fn def_log_level() -> String {
pub struct Config {
#[serde(default = "def_log_level")]
log_level: String,
latitude: f64,
longitude: f64,
pub latitude: f64,
pub longitude: f64,
#[cfg(feature = "graphql")]
#[serde(default)]
pub graphql: super::graphql::config::Config,
Expand Down
Loading
Loading