@@ -33,7 +33,7 @@ def tearDownClass(cls):
33
33
34
34
35
35
def test_env_var_with_eqaul_sign (self ):
36
- cmd = f"docker run --name envvarcheck -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9003:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.check_env_var_handler"
36
+ cmd = f"docker run --name envvarcheck -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9003:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.check_env_var_handler"
37
37
38
38
Popen (cmd .split (' ' )).communicate ()
39
39
@@ -44,7 +44,7 @@ def test_env_var_with_eqaul_sign(self):
44
44
self .assertEqual (b'"4=4"' , r .content )
45
45
46
46
def test_two_invokes (self ):
47
- cmd = f"docker run --name testing -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9000:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.success_handler"
47
+ cmd = f"docker run --name testing -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9000:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.success_handler"
48
48
49
49
Popen (cmd .split (' ' )).communicate ()
50
50
@@ -60,7 +60,7 @@ def test_two_invokes(self):
60
60
61
61
62
62
def test_timeout_invoke (self ):
63
- cmd = f"docker run --name timeout -d --env AWS_LAMBDA_FUNCTION_TIMEOUT=1 -v { self .path_to_binary } :/local-lambda-runtime-server -p 9001:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.sleep_handler"
63
+ cmd = f"docker run --name timeout -d --env AWS_LAMBDA_FUNCTION_TIMEOUT=1 -v { self .path_to_binary } :/local-lambda-runtime-server -p 9001:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.sleep_handler"
64
64
65
65
Popen (cmd .split (' ' )).communicate ()
66
66
@@ -71,7 +71,7 @@ def test_timeout_invoke(self):
71
71
self .assertEqual (b"Task timed out after 1.00 seconds" , r .content )
72
72
73
73
def test_exception_returned (self ):
74
- cmd = f"docker run --name exception -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9002:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.exception_handler"
74
+ cmd = f"docker run --name exception -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9002:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.exception_handler"
75
75
76
76
Popen (cmd .split (' ' )).communicate ()
77
77
@@ -105,7 +105,7 @@ def tearDownClass(cls):
105
105
Popen (f"docker rmi { cls .image_name } " .split (' ' )).communicate ()
106
106
107
107
def test_invoke_with_pre_runtime_api_runtime (self ):
108
- cmd = f"docker run --name testing -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9000:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.success_handler"
108
+ cmd = f"docker run --name testing -d -v { self .path_to_binary } :/local-lambda-runtime-server -p 9000:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.success_handler"
109
109
110
110
Popen (cmd .split (' ' )).communicate ()
111
111
@@ -116,7 +116,7 @@ def test_invoke_with_pre_runtime_api_runtime(self):
116
116
self .assertEqual (b'"My lambda ran succesfully"' , r .content )
117
117
118
118
def test_function_name_is_overriden (self ):
119
- cmd = f"docker run --name assert-overwritten -d --env AWS_LAMBDA_FUNCTION_NAME=MyCoolName -v { self .path_to_binary } :/local-lambda-runtime-server -p 9009:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-local { self .image_name } /bootstrap-with-handler main.assert_env_var_is_overwritten"
119
+ cmd = f"docker run --name assert-overwritten -d --env AWS_LAMBDA_FUNCTION_NAME=MyCoolName -v { self .path_to_binary } :/local-lambda-runtime-server -p 9009:8080 --entrypoint /local-lambda-runtime-server/aws-lambda-rie { self .image_name } /bootstrap-with-handler main.assert_env_var_is_overwritten"
120
120
121
121
Popen (cmd .split (' ' )).communicate ()
122
122
0 commit comments