| |
then command is successful
|
| |
|
| |
when I run cibtool --db ci-broker.db event list --json
|
| - |
then stdout contains "RefChanged"
|
| - |
then stdout contains ""oid": "0000000000000000000000000000000000000000""
|
| - |
then stdout contains ""old": "0000000000000000000000000000000000000000""
|
| + |
then stdout contains "BranchUpdated"
|
| + |
then stdout contains ""branch": "main""
|
| + |
then stdout contains ""tip": "0000000000000000000000000000000000000000""
|
| + |
then stdout contains ""old_tip": "0000000000000000000000000000000000000000""
|
| |
~~~
|
| |
|
| |
## Insert many events into queue
|
| |
then file events.json contains ""type":"refsFetched""
|
| |
~~~
|
| |
|
| - |
## Convert recorded node events into broker events
|
| + |
## Convert recorded node events into CI events
|
| |
|
| - |
_What:_ Node operator can see what broke events are created from node
|
| + |
_What:_ Node operator can see what CI events are created from node
|
| |
events.
|
| |
|
| - |
_Why:_ This is helpful so that node operators can see what broker
|
| - |
events are created from node events, which may have been previously
|
| - |
recorded. It's also helpful for CI broker developers as a development
|
| - |
tool.
|
| + |
_Why:_ This is helpful so that node operators can see what CI events
|
| + |
are created from node events, which may have been previously recorded.
|
| + |
It's also helpful for CI broker developers as a development tool.
|
| |
|
| |
_Who:_ `cib-dev`, `node-ops`
|
| |
|
| |
|
| |
given an installed cibtool
|
| |
when I run bash radenv.sh cibtool event record --output node-events.json
|
| - |
when I run bash radenv.sh cibtool event broker --output broker-events.json node-events.json
|
| - |
then file broker-events.json contains "RefChanged""
|
| + |
when I run bash radenv.sh cibtool event ci --output ci-events.json node-events.json
|
| + |
when I run cat ci-events.json
|
| + |
then file ci-events.json contains "BranchUpdated""
|
| |
~~~
|
| |
|
| |
|
| - |
## Filter recorded broker events
|
| + |
## Filter recorded CI events
|
| |
|
| - |
_What:_ Node operator can see what broker events an event filter
|
| - |
allow.
|
| + |
_What:_ Node operator can see what CI events an event filter allows.
|
| |
|
| |
_Why:_ This is helpful so that node operators can see verify their
|
| - |
event filter works as they expect.
|
| + |
event filters work as they expect.
|
| |
|
| |
_Who:_ `cib-dev`, `node-ops`
|
| |
|
| |
|
| |
given an installed cibtool
|
| |
when I run bash radenv.sh cibtool event record --output node-events.json
|
| - |
when I run bash radenv.sh cibtool event broker --output broker-events.json node-events.json
|
| + |
when I run bash radenv.sh cibtool event ci --output ci-events.json node-events.json
|
| |
|
| |
given file allow.yaml
|
| - |
when I run cibtool event filter allow.yaml broker-events.json
|
| - |
then stdout contains "RefChanged"
|
| + |
when I run cibtool event filter allow.yaml ci-events.json
|
| + |
then stdout contains "BranchUpdated"
|
| |
|
| |
given file deny.yaml
|
| - |
when I run cibtool event filter deny.yaml broker-events.json
|
| + |
when I run cibtool event filter deny.yaml ci-events.json
|
| |
then stdout is exactly ""
|
| |
~~~
|
| |
|