Created
September 30, 2019 16:14
-
-
Save murat-kilic/723702e0ce51bd3609fccd6c417d7f98 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void testExecuteFunction() { | |
assertTrue(client.addFunction("ExecuteMyFunction", "io.mark.java_examples.Executables.RunThisCode::addPerson")); | |
assertTrue(client.uploadFile("ExecuteMyFunction", "ExecutableCode-1.0-SNAPSHOT.jar")); | |
assertEquals(client.executeFunction("ExecuteMyFunction", "{\"firstName\":\"Mark\",\"lastName\":\"Kose\",\"age\":30,\"isActive\":false}"),"{\"fullName\":\"Mark Kose\",\"age\":30,\"shouldExerciseMore\":true}"); | |
AddPersonResponse person=(AddPersonResponse)client.executeFunction("ExecuteMyFunction","{\"firstName\":\"Mark\",\"lastName\":\"Kose\",\"age\":30,\"isActive\":false}","java"); | |
assertEquals(person.fullName,"Mark Kose"); | |
assertTrue(person.shouldExerciseMore); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment