()
| 44 | |
| 45 | #[test] |
| 46 | fn test_implicit_counter() { |
| 47 | let bump = Bump::new(); |
| 48 | let source = r#" |
| 49 | style-rule { collect: --total-rules; } |
| 50 | "#; |
| 51 | let css_source = r#" |
| 52 | .foo {} |
| 53 | #bar {} |
| 54 | .baz {} |
| 55 | "#; |
| 56 | let (counters, diagnostics) = run(&bump, source, css_source); |
| 57 | let a = CsskitAtomSet::get_dyn_set().atom_from_str("total-rules"); |
| 58 | assert_eq!(counters.get(&a), Some(&(StatType::Counter, 3))); |
| 59 | assert_eq!(diagnostics.len(), 0, "No diagnostics should be generated"); |
| 60 | } |
| 61 | |
| 62 | #[test] |
| 63 | fn test_bytes() { |
nothing calls this directly
no test coverage detected