()
| 1113 | |
| 1114 | #[test] |
| 1115 | fn minify_css() { |
| 1116 | let inliner = CSSInliner::options().minify_css(true).build(); |
| 1117 | let html = r#" |
| 1118 | <html> |
| 1119 | <head> |
| 1120 | <style> |
| 1121 | h1 { |
| 1122 | color: blue; |
| 1123 | font-weight: bold; |
| 1124 | } |
| 1125 | </style> |
| 1126 | </head> |
| 1127 | <body> |
| 1128 | <h1>Hello</h1> |
| 1129 | </body> |
| 1130 | </html>"#; |
| 1131 | let inlined = inliner.inline(html).unwrap(); |
| 1132 | let expected = "<html><head>\n\n</head>\n<body>\n<h1 style=\"color:blue;font-weight:bold\">Hello</h1>\n\n</body></html>"; |
| 1133 | assert_eq!(inlined, expected); |
| 1134 | } |
| 1135 | |
| 1136 | #[test] |
| 1137 | fn nth_child_selector() { |
nothing calls this directly
no test coverage detected