|
305 | 305 | ) |
306 | 306 |
|
307 | 307 | expect(series).to be_valid |
308 | | - expect(series.buckets).to contain_exactly( |
309 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.valid', date: ^two_days_ago, count: 8) }, |
310 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.expired', date: ^one_day_ago, count: 2) }, |
311 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.no-machine', date: ^one_day_ago, count: 3) }, |
312 | | - ) |
| 308 | + expect(series.buckets).to satisfy do |
| 309 | + it in [ |
| 310 | + Analytics::Series::Bucket(metric: 'validations.expired', date: ^one_day_ago, count: 2), |
| 311 | + Analytics::Series::Bucket(metric: 'validations.no-machine', date: ^one_day_ago, count: 3), |
| 312 | + Analytics::Series::Bucket(metric: 'validations.valid', date: ^two_days_ago, count: 8), |
| 313 | + ] |
| 314 | + end |
313 | 315 | end |
314 | 316 |
|
315 | 317 | it 'supports license filtering' do |
|
367 | 369 | ) |
368 | 370 |
|
369 | 371 | expect(series).to be_valid |
370 | | - expect(series.buckets).to contain_exactly( |
371 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.valid', date: ^one_day_ago, count: 5) }, |
372 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.valid', date: ^today, count: 3) }, |
373 | | - satisfy { it in Analytics::Series::Bucket(metric: 'validations.expired', date: ^today, count: 2) }, |
374 | | - ) |
| 372 | + expect(series.buckets).to satisfy do |
| 373 | + it in [ |
| 374 | + Analytics::Series::Bucket(metric: 'validations.expired', date: ^today, count: 2), |
| 375 | + Analytics::Series::Bucket(metric: 'validations.valid', date: ^one_day_ago, count: 5), |
| 376 | + Analytics::Series::Bucket(metric: 'validations.valid', date: ^today, count: 3), |
| 377 | + ] |
| 378 | + end |
375 | 379 | end |
376 | 380 |
|
377 | 381 | it 'overwrites stale spark data for today with realtime count' do |
|
0 commit comments