- Implemented `owl_to_mermaid.py` to convert OWL/Turtle files into Mermaid class diagrams. - Implemented `owl_to_plantuml.py` to convert OWL/Turtle files into PlantUML class diagrams. - Added two new PlantUML files for custodian multi-aspect diagrams.
4.5 KiB
4.5 KiB
Task 7 Manual Testing Guide
Prerequisites
- ✅ Oxigraph server running:
http://localhost:7878/query - ✅ Vite dev server running:
http://localhost:5174 - ✅ Sample data loaded (78 triples)
Test Checklist
1. Query Execution ✓
- Open http://localhost:5174/query-builder
- Click "List Museums" template in left sidebar
- Verify SPARQL query appears in editor
- Click "Execute Query" button
- Verify results table appears below
- Check that museum names are displayed
2. Results Table Features ✓
- Sorting: Click column headers to sort
- First click: ascending (↑)
- Second click: descending (↓)
- Third click: remove sort
- Pagination: If >100 results, verify pagination controls work
- Click "Next Page" / "Previous Page"
- Page numbers display correctly
- Cell Types: Verify rendering
- URIs display as clickable links
- Literals display as plain text
- Language-tagged literals show language (e.g., "Museum"@en)
- Copy to Clipboard: Click copy icon for individual cells
3. Export Functionality ✓
- Click "Export as CSV" - downloads file
- Click "Export as JSON" - downloads file
- Click "Export as JSON-LD" - downloads file
- Open each file and verify format is correct
4. Error Handling ✓
- Stop Oxigraph:
kill $(cat /tmp/oxigraph-server.pid) - Execute a query
- Verify error message appears with helpful hint
- Restart Oxigraph:
./scripts/load-and-start.sh - Execute query again - should work
5. Ontology Visualization ✓
- Click "Show Ontology Diagram" button
- Verify Mermaid diagram renders below results
- Test zoom controls:
- Click "+" to zoom in
- Click "-" to zoom out
- Click "Reset Zoom"
- Click "Download as SVG" - downloads diagram
- Click "Regenerate" to refresh diagram
- Click "Hide Ontology Diagram" to close
6. Query Templates ✓
Test each template from sidebar:
- List Museums
- Count by Type
- Institutions with Locations
- Museums with ISIL codes
- Prefix Explorer
- Custom query (blank slate)
7. Visual Builder ✓
- Switch to "Visual Builder" tab
- Add patterns, filters, etc.
- Verify SPARQL generates in preview
- Execute from visual builder
- Switch back to "SPARQL Editor" tab
8. Save/Load Queries ✓
- Write a custom query
- Click "Save Query"
- Enter name and save
- Verify it appears in "Saved Queries" section
- Click saved query to load it
- Click "×" to delete saved query
9. Copy to Clipboard ✓
- Write or load a query
- Click "Copy to Clipboard"
- Paste elsewhere to verify
10. Validation ✓
- Enter invalid SPARQL (e.g.,
SELECT * WHERR { ?s ?p ?o }) - Verify validation errors appear
- "Execute Query" button should be disabled
- Fix error and verify validation passes
Sample Queries to Test
Query 1: Count All Triples
SELECT (COUNT(*) as ?count) WHERE {
?s ?p ?o
}
Expected: 1 row with count = 78
Query 2: List All Museums
PREFIX schema: <http://schema.org/>
SELECT ?museum ?name WHERE {
?museum a schema:Museum ;
schema:name ?name .
}
Expected: Multiple rows with museum URIs and names
Query 3: Museums with Cities
PREFIX schema: <http://schema.org/>
SELECT ?museum ?name ?city WHERE {
?museum a schema:Museum ;
schema:name ?name ;
schema:address ?addr .
?addr schema:addressLocality ?city .
}
Expected: Museums with their city names
Query 4: ASK Query (Boolean)
PREFIX schema: <http://schema.org/>
ASK WHERE {
?museum a schema:Museum .
}
Expected: Results table with boolean response
Query 5: CONSTRUCT Query
PREFIX schema: <http://schema.org/>
CONSTRUCT {
?museum schema:name ?name .
} WHERE {
?museum a schema:Museum ;
schema:name ?name .
FILTER (LANG(?name) = "en")
}
Expected: RDF triples in results
Known Issues
- ⚠️ One pre-existing test failure in
use-rdf-parser.test.ts(unrelated to Task 7) - ⚠️ Oxigraph ARM persistence bug - using in-memory mode only
Success Criteria
- All 210 tests passing (excluding 1 pre-existing fail)
- Manual tests complete (10/10 sections)
- No console errors in browser
- Export downloads work
- Ontology visualization renders
Next Steps After Testing
- Fix any bugs discovered
- Add loading spinner for query execution
- Improve error messages
- Add result count badge
- Consider GraphContext integration (Step 3)