We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 742a6c0 commit fa2d42bCopy full SHA for fa2d42b
1 file changed
tests/src/test/scala/runtime/actionContainers/ActionProxyContainerTests.scala
@@ -252,4 +252,20 @@ class ActionProxyContainerTests extends BasicActionRunnerTests with WskActorSyst
252
e shouldBe empty
253
})
254
}
255
+
256
+ it should "support current directory be action location" in {
257
+ withActionContainer() { c =>
258
+ val code = """
259
+ |#!/bin/bash
260
+ |echo "{\"pwd_env\":\"$PWD\",\"pwd_cmd\":\"$(pwd)\"}"
261
+ """.stripMargin.trim
262
263
+ val (initCode, initRes) = c.init(initPayload(code))
264
+ initCode should be(200)
265
266
+ val (_, runRes) = c.run(runPayload(JsObject()))
267
+ runRes.get.fields.get("pwd_env") shouldBe Some(JsString("/action"))
268
+ runRes.get.fields.get("pwd_cmd") shouldBe Some(JsString("/action"))
269
+ }
270
271
0 commit comments