researchIdeas-story Pub

send::  msg etrieve.status 

expect::  (errcode is 0)

Need to test that the logic for finding the response template works

/$send wiki.content(wpath="AnAuthXmlReq", result="request") /$send snakk.text(url="/diesel/mock/tempus.pspapi", verb="POST", body=request) /$expect (payload contains "TRANRESP")

// $send ctx.set(objsample = snakk.json (url = "/diesel/mock/etrieve.status")) // $send ctx.set(expectedStatus = {

val expectedStatus:JSON={ "buildTimestamp": "2019-04-17T14:57:42-04:00", "serverIp": "", "source": "", "buildNumber": "1.47", "appDistName": "transprt-1.47", "timestamp": "2019-04-18T20:32:10.854Z", "status": "S" }

/$send snakk.text(url="/diesel/mock/tempus.pspapi", verb="POST", body=request)

TODO make this work - json exprs don't understand string expr well

=> diesel.db.col.upsert(collection="Cron", document={ name : "device-", schedule : "600 seconds", singleton : "yes", collect: 5, max: max, cronMsg: "$msg blinq.cron.tick(deviceId="${deviceId}", deviceType="${deviceType}", url="${urlToPost}")", count=2 })

null check flatmap

x?.y?.z doesn't blow up with null if one is undefined -> just results in undefined.

OR should the behavior of aexprident be controlled by a setting and be "strict" vs "lax"?

message lambdas with closure

d.repeat(msg=a.b(x?,y?, z=3))

Was this useful?    

By: Razie | 2019-04-18 .. 2020-10-06 | Tags: story , dsl , research

Viewed 230 times ( | History | Print ) this page.

You need to log in to post a comment!

© Copyright DieselApps, 2012-2022, all rights reserved.