(code: string)
| 352 | |
| 353 | describe('a call on a value of the parameter\'s type', () => { |
| 354 | const body = (code: string): Record<string, string> => ({ |
| 355 | 'shards.h': lines( |
| 356 | 'struct Inner { void Deep() {} };', |
| 357 | 'struct FastShard { using Part = Inner; void Clear() {} };', |
| 358 | 'struct SlowShard { using Part = Inner; void Clear() {} };', |
| 359 | ), |
| 360 | 'cache.h': lines( |
| 361 | '#include "shards.h"', |
| 362 | 'template <typename Shard>', |
| 363 | 'class Cache {', |
| 364 | ' public:', |
| 365 | code, |
| 366 | ' private:', |
| 367 | ' Shard own_;', |
| 368 | ' Shard* many_;', |
| 369 | '};', |
| 370 | ), |
| 371 | 'use.cc': lines('#include "cache.h"', 'Cache<FastShard> fast;', 'Cache<SlowShard> slow;'), |
| 372 | }); |
| 373 | const CLEARS = ['FastShard::Clear', 'SlowShard::Clear']; |
| 374 | |
| 375 | it.each([ |
no test coverage detected