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

Correct writeback_state sequence test #450

Merged
merged 29 commits into from
Sep 21, 2022
Merged
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
17f0676
fix writeback sequence test to work as expected
noursaidi Sep 9, 2022
13dacfd
Update generated.md
noursaidi Sep 9, 2022
1ed02c9
Adding test sequence sample out
grafnu Sep 9, 2022
40fa743
add ci check for validator/sequences
noursaidi Sep 9, 2022
37471cb
change clone_model checkout target
noursaidi Sep 12, 2022
6e76c83
Update sequence-generator to work with property maps (#15)
grafnu Sep 13, 2022
be9b7fb
new generated.md (but not comitted validator proofs)
noursaidi Sep 13, 2022
6649742
commit sequencer proofs (expect pass)
noursaidi Sep 13, 2022
6ab4205
Fixing semantic dates for discovery (#16)
grafnu Sep 13, 2022
12a967c
add sequencer output files
noursaidi Sep 13, 2022
05b93a1
sequencer.out
noursaidi Sep 13, 2022
b32f1a1
Merge branch 'master' into writeback_test1
noursaidi Sep 14, 2022
a990010
restore gcp_device_logs
noursaidi Sep 14, 2022
04357df
comments - clone model and gitattributes
noursaidi Sep 14, 2022
65d9ed5
Merge branch 'master' into writeback_test1
noursaidi Sep 20, 2022
dd55bd5
remove irrelevant log files
noursaidi Sep 20, 2022
9de2072
remove extra valid_serial_no from sequencer.out
noursaidi Sep 20, 2022
779f38a
sequencer.out
noursaidi Sep 20, 2022
f4e745b
Fix recusrion (#17)
grafnu Sep 20, 2022
99a92e7
test ci - expect failure
noursaidi Sep 20, 2022
d072d15
Merge branch 'writeback_test1' of github.com:noursaidi/udmi into writ…
noursaidi Sep 20, 2022
06d1437
flip validation directory and add generated.md
noursaidi Sep 20, 2022
5d1a6b7
generated.md extra line
noursaidi Sep 20, 2022
781955f
add endpoint_config (expect fail)
noursaidi Sep 20, 2022
d4718b4
expect pass
noursaidi Sep 20, 2022
1ecc1c2
fix
noursaidi Sep 21, 2022
9dca779
empty
noursaidi Sep 21, 2022
448b5be
add logging to ci
noursaidi Sep 21, 2022
6a81454
remove additional logging
noursaidi Sep 21, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,10 @@ jobs:
more /tmp/sequencer.out
diff -u /tmp/sequencer.out etc/sequencer.out && echo No sequencer.out diff
diff -u /tmp/generated.md docs/specs/sequences/generated.md && echo No generated.md diff
(ls -1 validator/sequences | xargs -I% diff -u \
sites/udmi_site_model/out/devices/AHU-1/tests/%/sequence.md \
validator/sequences/%/sequence.md) \
&& echo Sequences in validator/sequences up to date
- name: telemetry validator
env:
GCP_TARGET_PROJECT: ${{ secrets.GCP_TARGET_PROJECT }}
Expand Down
2 changes: 1 addition & 1 deletion bin/clone_model
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ mkdir -p $ROOT_DIR/sites
cd $ROOT_DIR/sites

MODEL_DIR=udmi_site_model
MODEL_VER=1.7
MODEL_VER=808aa06fbe922b9f749d2a6b52ff03b6f9074b48
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs 1.8 tag

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do, but you also need to create a 1.8 tag for that repo.

TEST_SITE_GIT=https://github.com/faucetsdn/$MODEL_DIR.git
MODEL_REPO=origin

Expand Down
15 changes: 14 additions & 1 deletion docs/specs/sequences/generated.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ Check that the device correctly handles an extra out-of-schema field
1. Update config:
* Add `discovery` = { "families": { } }
1. Wait for all scans not active
1. Update config:
* Add `discovery.families.virtual` = { "generation": _family generation_, "scan_interval_sec": `10`, "enumerate": `true` }
1. Wait for scan iterations

## self_enumeration
Expand All @@ -107,6 +109,8 @@ Check that the device correctly handles an extra out-of-schema field
1. Update config:
* Add `discovery` = { "families": { } }
1. Wait for all scans not active
1. Update config:
* Add `discovery.families.virtual` = { "generation": _family generation_, "enumerate": `true` }
1. Wait for scheduled scan start
1. Wait for scan activation
1. Wait for scan completed
Expand Down Expand Up @@ -134,4 +138,13 @@ Check that the min log-level config is honored by the device.

## writeback_states

1. Test failed: Missing 'invalid' target specification
1. Wait for point filter_differential_pressure_sensor to have value_state default (null)
1. Wait for point filter_alarm_pressure_status to have value_state default (null)
1. Wait for point filter_differential_pressure_setpoint to have value_state default (null)
1. Update config:
* Add `pointset.points.filter_alarm_pressure_status.set_value` = `false`
* Set `pointset.points.filter_differential_pressure_setpoint.set_value` = `60`
* Add `pointset.points.filter_differential_pressure_sensor.set_value` = `15`
1. Wait for point filter_differential_pressure_sensor to have value_state invalid
1. Wait for point filter_alarm_pressure_status to have value_state failure
1. Wait for point filter_differential_pressure_setpoint to have value_state applied
17 changes: 0 additions & 17 deletions docs/tools/gcloud.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,3 @@ them to work out-of-the-box without a deeper understanding of what's going on!
# Update a device's GCP IoT Core configuration

`bin/reset_config`

# Viewing Device GCP Cloud Logging

`bin/gcloud_device_logs PROJECT_ID DEVICE_ID [DEVICE_ID ...]`

```
2022-09-01 14:35:07.677668+00:00 GAT-100 ZZ-TRI-FECTA PUBLISH STATE (RESOURCE_EXHAUSTED The device "2582332477650079" could not be updated. Device state can be updated only once every 1s.)
2022-09-01 14:35:07.679536+00:00 GAT-100 ZZ-TRI-FECTA DISCONNECT (RESOURCE_EXHAUSTED The device "2582332477650079" could not be updated. Device state can be updated only once every 1s.)
2022-09-01 14:35:19.115078+00:00 GAT-100 ZZ-TRI-FECTA CONNECT
2022-09-01 14:35:23.637210+00:00 GAT-100 ZZ-TRI-FECTA SUBSCRIBE /devices/GAT-100/config
2022-09-01 14:35:23.653924+00:00 GAT-100 ZZ-TRI-FECTA SUBSCRIBE /devices/GAT-100/commands/#
2022-09-01 14:35:23.654129+00:00 GAT-100 ZZ-TRI-FECTA SUBSCRIBE /devices/GAT-100/errors
2022-09-01 14:35:24.491455+00:00 GAT-100 ZZ-TRI-FECTA PUBACK CONFIG
2022-09-01 14:35:24.491506+00:00 GAT-100 ZZ-TRI-FECTA CONFIG
2022-09-01 14:35:24.632056+00:00 GAT-100 ZZ-TRI-FECTA PUBLISH STATE
2022-09-01 14:35:25.094994+00:00 ACT-1 ZZ-TRI-FECTA ATTACH_TO_GATEWAY GAT-100
```
2 changes: 1 addition & 1 deletion etc/sequencer.out
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ RESULT pass system_min_loglevel Sequence complete
RESULT pass valid_serial_no Sequence complete
RESULT pass valid_serial_no Sequence complete
RESULT pass valid_serial_no Sequence complete
RESULT skip writeback_states Missing 'invalid' target specification
RESULT pass writeback_states Sequence complete

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/bin/build
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ fi

export JAVA_HOME=$JAVA_HOME_11_X64

echo Building validataor in $PWD
echo Building validator in $PWD

rm -rf build
./gradlew shadow $check
Expand Down
2 changes: 1 addition & 1 deletion validator/sequences/broken_config/config_pointset.attr

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions validator/sequences/broken_config/config_pointset.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/sequences/broken_config/config_system.attr

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions validator/sequences/broken_config/config_system.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/sequences/broken_config/config_update.attr

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions validator/sequences/broken_config/config_update.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/sequences/broken_config/event_pointset.attr

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions validator/sequences/broken_config/event_pointset.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/sequences/broken_config/event_system.attr

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions validator/sequences/broken_config/event_system.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions validator/sequences/broken_config/local_config.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion validator/sequences/broken_config/local_system.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading