A full-stack text-based Computer-Aided Software Engineering (CASE) tool that supports requirements management, testing, and modeling through a unified interface.
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
- Requirements management
- Test case management
- Modeling support
- Text-based interface
- Web interface
- Command-line interface
- Python 3.11 or higher
- Poetry (for dependency management)
- pyenv (recommended for Python version management)
-
Clone the repository
git clone https://github.com/yourusername/textcase.git cd textcase
-
Set up Python version
pyenv install 3.11.12 # If not already installed pyenv local 3.11.12 # Set local Python version
-
Install dependencies
poetry install
Create a new module with the specified prefix and path.
# Create a new module
poetry run tse create <PREFIX> <MODULE_PATH>
# Example: Create a requirements module
poetry run tse create REQ ./reqs/
# Create a submodule with a parent reference
poetry run tse create TST ./reqs/tests --parent REQ
# Customize ID format with separator and digits
poetry run tse create REQ ./reqs/ --sep "-" --digits 4 # Creates IDs like REQ-0001
Add a new case item to a module.
# Add a new case item with auto-generated ID
poetry run tse add <MODULE_PREFIX>
# Add a new case item with custom string name
poetry run tse add -n FOOBAR <MODULE_PREFIX>
# Add a new case item with custom numeric ID
poetry run tse add -n 3 <MODULE_PREFIX> # Will format as 003 based on module settings
Edit an existing document using the system editor.
# Edit a document by ID
poetry run tse edit <DOC_ID>
# Examples
poetry run tse edit REQ1 # Edit REQ001.md (with leading zeros based on module settings)
poetry run tse edit REQ001 # Edit REQ001.md directly
poetry run tse edit TST42 # Edit TST042.md in the TST module
Create links between documents.
# Link two documents (source -> target)
poetry run tse link <SOURCE> <TARGET>
# Link with a specific label
poetry run tse link <SOURCE> <TARGET> -l "related"
# Examples
poetry run tse link TST1 REQ1 # Link TST001 to REQ001 with no label
poetry run tse link TST1 REQ1 -l "verifies" # Link with a specific label
poetry run tse link TST001 REQ001 # Link using full IDs
A TextCase project typically follows this structure:
project_root/
βββ .textcase.yml # Project configuration
βββ reqs/ # Requirements documents (REQ module)
β βββ REQ001.md # Requirement document
β βββ tests/ # Test cases (TST submodule)
β βββ TST001.md # Test case document
βββ docs/ # Documentation
TextCase uses Markdown files with YAML frontmatter for document metadata:
---
links:
REQ001: [] # Link with no label
REQ002: # Link with labels
- "verifies"
- "implements"
---
# TST001: Test Case Title
Test case description goes here...
Add the -v
or --verbose
flag to get detailed debug output:
poetry run tse -v link TST1 REQ1
# Set the editor for editing documents
export EDITOR=code # Use VS Code
# Enable direct editing (default)
export USE_DIRECT_EDIT=1
-
Install development dependencies
poetry install --with dev
-
Run tests
poetry run pytest
- Code formatting:
black .
- Import sorting:
isort .
- Linting:
flake8
- Type checking:
mypy .
- Testing:
pytest
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.