Codeception / Codeception/AspectMock

How can i past a double to a class contructor?

Open
#182 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
784
Forks
132
PR merge metrics
No merged PRs in 30d

Description

the following doesnt' work
```
$ck = test::double(CacheKey::class, [ 'track' => null,])->make();

$cityConfigProvider = new CityConfigProvider($cityConfigBuilder, $ck); // failed for $ck is not an instance of CacheKey
$ck->verifyInvoked('track');

$value = $cityConfigProvider->get($cityId, 'wechat_app_Id');
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.