(ctx context.Context, key string)
| 207 | } |
| 208 | |
| 209 | func contextRecordFrom(ctx context.Context, key string) contextRecord { |
| 210 | record := contextRecord{ |
| 211 | key: key, |
| 212 | canceled: errors.Is(ctx.Err(), context.Canceled), |
| 213 | } |
| 214 | if value, ok := ctx.Value(markerKey).(string); ok { |
| 215 | record.value = value |
| 216 | } |
| 217 | return record |
| 218 | } |
| 219 | |
| 220 | func (s *contextRecorderStorage) GetWithContext(ctx context.Context, key string) ([]byte, error) { |
| 221 | s.gets = append(s.gets, contextRecordFrom(ctx, key)) |
no test coverage detected
searching dependent graphs…