         self.htmlSource = try? String(contentsOf: sourceURL!, encoding: .utf8)
         
         XCTAssertNotNil(self.htmlSource)
+    }
+    
+    
+    func testAllSyntaxStyles() {
+        
+        for (name, dict) in self.styleDicts {
+            for error in SyntaxStyleValidator.validate(dict) {
+                XCTFail("\(name) \(error.errorDescription!) -> \(error.failureReason!)")
+            }
+        }
     }
     
     

        
        let bundle = Bundle(for: type(of: self))
        
        // load XML style
        let styleURL = bundle.url(forResource: "HTML", withExtension: styleExtension, subdirectory: styleDirectoryName)
        let data = try! Data(contentsOf: styleURL!)
        let dict = try! YAMLSerialization.object(withYAMLData: data, options: kYAMLReadOptionMutableContainersAndLeaves) as! [String: Any]
        self.htmlStyle = SyntaxStyle(dictionary: dict, name: "HTML")
        
        XCTAssertNotNil(self.htmlStyle)
        


class SyntaxTests: XCTestCase, SyntaxParserDelegate {
    
    var styleDicts: [String: SyntaxManager.StyleDictionary] = [:]
    var htmlStyle: SyntaxStyle?
    var htmlSource: String?
    
