Skip to content

Commit 6694e2c

Browse files
Update ActorStateIT.java
Ensure the test compiles and uses the right DaprRun instance.
1 parent 39340c4 commit 6694e2c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sdk-tests/src/test/java/io/dapr/it/actors/ActorStateIT.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ public void writeReadState() throws Exception {
174174
public void stateTTL(AppRun.AppProtocol serviceAppProtocol) throws Exception {
175175
logger.debug("Starting actor runtime ...");
176176
// The call below will fail if service cannot start successfully.
177-
DaprRun runtime = startDaprApp(
177+
DaprRun run = startDaprApp(
178178
this.getClass().getSimpleName(),
179179
StatefulActorService.SUCCESS_MESSAGE,
180180
StatefulActorService.class,
@@ -190,7 +190,7 @@ public void stateTTL(AppRun.AppProtocol serviceAppProtocol) throws Exception {
190190
String actorType = "StatefulActorTest";
191191
logger.debug("Building proxy ...");
192192
ActorProxyBuilder<ActorProxy> proxyBuilder =
193-
new ActorProxyBuilder(actorType, ActorProxy.class, newActorClient());
193+
new ActorProxyBuilder(actorType, ActorProxy.class, deferClose(run.newActorClient());
194194
ActorProxy proxy = proxyBuilder.build(actorId);
195195

196196
// wating for actor to be activated
@@ -231,7 +231,7 @@ public void stateTTL(AppRun.AppProtocol serviceAppProtocol) throws Exception {
231231
serviceAppProtocol);
232232

233233
// Need new proxy builder because the proxy builder holds the channel.
234-
proxyBuilder = new ActorProxyBuilder(actorType, ActorProxy.class, newActorClient());
234+
proxyBuilder = new ActorProxyBuilder(actorType, ActorProxy.class, deferClose(run2.newActorClient());
235235
ActorProxy newProxy = proxyBuilder.build(actorId);
236236

237237
// waiting for actor to be activated

0 commit comments

Comments
 (0)