Run all validation checks and return True if all pass.
(self)
| 26 | } |
| 27 | |
| 28 | def validate(self): |
| 29 | """Run all validation checks and return True if all pass.""" |
| 30 | # Test 0: XML well-formedness |
| 31 | if not self.validate_xml(): |
| 32 | return False |
| 33 | |
| 34 | # Test 1: Namespace declarations |
| 35 | all_valid = True |
| 36 | if not self.validate_namespaces(): |
| 37 | all_valid = False |
| 38 | |
| 39 | # Test 2: Unique IDs |
| 40 | if not self.validate_unique_ids(): |
| 41 | all_valid = False |
| 42 | |
| 43 | # Test 3: UUID ID validation |
| 44 | if not self.validate_uuid_ids(): |
| 45 | all_valid = False |
| 46 | |
| 47 | # Test 4: Relationship and file reference validation |
| 48 | if not self.validate_file_references(): |
| 49 | all_valid = False |
| 50 | |
| 51 | # Test 5: Slide layout ID validation |
| 52 | if not self.validate_slide_layout_ids(): |
| 53 | all_valid = False |
| 54 | |
| 55 | # Test 6: Content type declarations |
| 56 | if not self.validate_content_types(): |
| 57 | all_valid = False |
| 58 | |
| 59 | # Test 7: XSD schema validation |
| 60 | if not self.validate_against_xsd(): |
| 61 | all_valid = False |
| 62 | |
| 63 | # Test 8: Notes slide reference validation |
| 64 | if not self.validate_notes_slide_references(): |
| 65 | all_valid = False |
| 66 | |
| 67 | # Test 9: Relationship ID reference validation |
| 68 | if not self.validate_all_relationship_ids(): |
| 69 | all_valid = False |
| 70 | |
| 71 | # Test 10: Duplicate slide layout references validation |
| 72 | if not self.validate_no_duplicate_slide_layouts(): |
| 73 | all_valid = False |
| 74 | |
| 75 | return all_valid |
| 76 | |
| 77 | def validate_uuid_ids(self): |
| 78 | """Validate that ID attributes that look like UUIDs contain only hex values.""" |
no test coverage detected