Browse Source

[#36813] ci: Added script for testing interactive plot

check-vt100
Marcelina Oset 3 years ago
parent
commit
6ffebf54d6
  1. 32
      .ci.yml
  2. 4
      graph.py

32
.ci.yml

@ -43,3 +43,35 @@ simple_test:
- "*.ascii"
- "*.txt"
- "*.log"
interactive_plot_test:
variables:
FAKE_DISK: "fake_disk.ext4"
FAKE_MOUNTPOINT: "fake_mountpoint"
script:
- pip install git+https://github.com/antmicro/servis#egg=servis[bokeh]
- dd if=/dev/zero of=$FAKE_DISK bs=1M count=130
- mkfs.ext4 $FAKE_DISK
- mkdir -p $FAKE_MOUNTPOINT && mount $FAKE_DISK $FAKE_MOUNTPOINT
- sargraph chart start -m $FAKE_MOUNTPOINT
- pushd $FAKE_MOUNTPOINT
- df -h .
- stress -c 16 -i 1 -m 1 --vm-bytes 512M -d 1 --hdd-bytes 70M -t 160s
- popd
- sargraph chart save plot.html
- sargraph chart stop
- test -f plot.html
- cat chart.log
artifacts:
when: always
paths:
- "*.txt"
- "*.log"
- "*.html"

4
graph.py

@ -440,8 +440,8 @@ def servis_graph(session, fname='plot', output_ext='ascii'):
[None]*5,
y_titles,
[None]*5,
# [(0, 160)]*5,
# [(0, 100)]*5,
[(0, 160)]*5,
[(0, 100)]*5,
outpath=Path(fname),
outputext=['html'],
trimxvalues=False,

Loading…
Cancel
Save