rwml 0.1.0

Native Rust toolkit for Microsoft Word — read, write, edit, and render legacy .doc (Word 97-2003, [MS-DOC]) and modern .docx (OOXML): one document model, package-preserving edits, field evaluation, Markdown/HTML export, PDF preview
Documentation
import pathlib
import unittest


WORKFLOW = (
    pathlib.Path(__file__).resolve().parents[1] / ".github" / "workflows" / "ci.yml"
)


class CiWorkflowTests(unittest.TestCase):
    def test_ci_workflow_runs_public_hygiene_audit(self):
        text = WORKFLOW.read_text(encoding="utf-8")

        self.assertIn("python3 scripts/public_hygiene_audit.py", text)

    def test_ci_workflow_runs_no_default_gate(self):
        text = WORKFLOW.read_text(encoding="utf-8")

        self.assertIn("cargo test --all-targets", text)
        self.assertIn("cargo test --no-default-features", text)
        self.assertIn("cargo test --all-targets --features render", text)

    def test_ci_workflow_builds_no_default_msrv_surface(self):
        text = WORKFLOW.read_text(encoding="utf-8")

        self.assertIn("dtolnay/rust-toolchain@1.85.0", text)
        self.assertIn("dtolnay/rust-toolchain@1.92.0", text)
        self.assertIn("cargo build --no-default-features", text)


if __name__ == "__main__":
    unittest.main()