| 140 | } |
| 141 | |
| 142 | void MockAssetLoader::handleResponse(const Ref<AssetLoaderCompletion>& completion, |
| 143 | const Result<Ref<Valdi::LoadedAsset>>& result) { |
| 144 | { |
| 145 | std::lock_guard<Mutex> lock(_mutex); |
| 146 | |
| 147 | bool foundCompletion = false; |
| 148 | for (const auto& it : _completions) { |
| 149 | if (it.lock() == completion) { |
| 150 | foundCompletion = true; |
| 151 | break; |
| 152 | } |
| 153 | } |
| 154 | |
| 155 | if (!foundCompletion) { |
| 156 | return; |
| 157 | } |
| 158 | } |
| 159 | |
| 160 | completion->onLoadComplete(result); |
| 161 | } |
nothing calls this directly
no test coverage detected