Drone pipeline met unit test toegevoegd
This commit is contained in:
30
docs/dumpserie
Executable file
30
docs/dumpserie
Executable file
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
from lmwsip import LmwSip
|
||||
from datetime import datetime, timedelta
|
||||
from pprint import pprint
|
||||
|
||||
def printLocPar(sip, proces, loc, par, start, end):
|
||||
try:
|
||||
r = sip.timeSerie(proces, loc, par, start, end)
|
||||
except Exception as e:
|
||||
print(e)
|
||||
print("\n%s %s %s:\n" % (proces, loc, par))
|
||||
pprint(r.ts)
|
||||
|
||||
def main():
|
||||
end = datetime.now() + timedelta(minutes=10)
|
||||
start = end - timedelta(hours=1)
|
||||
|
||||
try:
|
||||
sip = LmwSip("<user>", "<pass>")
|
||||
except Exception as e:
|
||||
print(e)
|
||||
|
||||
printLocPar(sip, "WN", "HOEK", "H10", start, end)
|
||||
printLocPar(sip, "WN", "LEG1", "Czz10", start, end)
|
||||
printLocPar(sip, "VW", "HOEK", "H10V", start, end)
|
||||
printLocPar(sip, "AS", "HOEK", "H10A", start, end)
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
4
docs/hoek-h10.sip
Normal file
4
docs/hoek-h10.sip
Normal file
@@ -0,0 +1,4 @@
|
||||
LI USER,PASS
|
||||
TI LMW
|
||||
WN LMW,HOEK,H10,-01:00,{DATE},{TIME},DATA
|
||||
LO
|
8
docs/lmwsip-test
Executable file
8
docs/lmwsip-test
Executable file
@@ -0,0 +1,8 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
from lmwsip import LmwSip
|
||||
|
||||
lmwsip = LmwSip("USER", "PASS")
|
||||
print(lmwsip.ti())
|
||||
print(lmwsip.value("WN", "HOEK", "H10"))
|
||||
lmwsip.logout()
|
Reference in New Issue
Block a user