From 3619fbac8c3bb456c3f5618c5f630976310b45d5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:12:06 +0000 Subject: [PATCH 1/8] Initial plan From 3c3f5f777f0744a78edb8d707094b8e3338aecba Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:32:36 +0000 Subject: [PATCH 2/8] Phase 1: Critical fixes - gitignore, date typo, build workflow, code formatting Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .github/workflows/build.yaml | 7 +++++++ .gitignore | 8 ++++++++ ARCHITECTURE.md | 2 +- src/DemaConsulting.ReqStream/Program.cs | 14 +++++++------- src/DemaConsulting.ReqStream/TraceMatrix.cs | 4 ++-- src/DemaConsulting.ReqStream/Validation.cs | 16 ++++++++-------- .../ProgramTests.cs | 8 ++++---- .../TraceMatrixTests.cs | 2 +- 8 files changed, 38 insertions(+), 23 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f2c75f9..8584530 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -271,6 +271,13 @@ jobs: pattern: '*test-results*' continue-on-error: true + - name: Download integration test results + uses: actions/download-artifact@v7 + with: + path: test-results + pattern: 'integration-test-results-*' + continue-on-error: true + - name: Download package uses: actions/download-artifact@v7 with: diff --git a/.gitignore b/.gitignore index 158b3b0..59f7cdb 100644 --- a/.gitignore +++ b/.gitignore @@ -125,3 +125,11 @@ docs/requirements/requirements.md docs/tracematrix/*.html docs/tracematrix/tracematrix.md docs/*.pdf + +# Agent-generated reports (should not be committed) +AGENT_REPORT_*.md +*-review-report.md +CODE_QUALITY_REPORT.md +DOCUMENTATION_REVIEW.md +matrix.md +tracematrix.md diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index 0f1e0c5..b869324 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -975,6 +975,6 @@ private void ReadFile(string path) **Document Version**: 1.0 -**Last Updated**: 2026-01-11 +**Last Updated**: 2025-01-11 For questions or suggestions about this architecture document, please open an issue or submit a pull request. diff --git a/src/DemaConsulting.ReqStream/Program.cs b/src/DemaConsulting.ReqStream/Program.cs index 97cd2e5..0a4307c 100644 --- a/src/DemaConsulting.ReqStream/Program.cs +++ b/src/DemaConsulting.ReqStream/Program.cs @@ -1,4 +1,4 @@ -// Copyright (c) 2026 DEMA Consulting +// Copyright (c) 2026 DEMA Consulting // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal @@ -51,12 +51,12 @@ private static int Main(string[] args) try { // Create context from arguments - using var context = Context.Create(args); - - // Run the program logic - Run(context); - - // Return the exit code from the context + using var context = Context.Create(args); + + // Run the program logic + Run(context); + + // Return the exit code from the context return context.ExitCode; } catch (ArgumentException ex) diff --git a/src/DemaConsulting.ReqStream/TraceMatrix.cs b/src/DemaConsulting.ReqStream/TraceMatrix.cs index e15bd97..7936297 100644 --- a/src/DemaConsulting.ReqStream/TraceMatrix.cs +++ b/src/DemaConsulting.ReqStream/TraceMatrix.cs @@ -114,7 +114,7 @@ public IReadOnlyDictionary GetAllTestResults() var results = new Dictionary(); var requiredTests = new HashSet(); CollectRequiredTestNames(_requirements, requiredTests); - + foreach (var testName in requiredTests) { var result = GetTestResult(testName); @@ -124,7 +124,7 @@ public IReadOnlyDictionary GetAllTestResults() results[testName] = result; } } - + return results; } diff --git a/src/DemaConsulting.ReqStream/Validation.cs b/src/DemaConsulting.ReqStream/Validation.cs index 3a37441..92cefe0 100644 --- a/src/DemaConsulting.ReqStream/Validation.cs +++ b/src/DemaConsulting.ReqStream/Validation.cs @@ -134,8 +134,8 @@ private static void RunRequirementsProcessingTest(Context context, DemaConsultin { // Verify log contains expected output (read after context is disposed to ensure log is flushed) var logContent = File.ReadAllText(logFile); - - if (logContent.Contains("Reading 1 requirements file(s)") && + + if (logContent.Contains("Reading 1 requirements file(s)") && logContent.Contains("Requirements loaded successfully")) { test.Outcome = DemaConsulting.TestResults.TestOutcome.Passed; @@ -207,7 +207,7 @@ private static void RunTraceMatrixTest(Context context, DemaConsulting.TestResul { // Run the program with trace matrix (using relative paths) int exitCode; - using (var testContext = Context.Create(["--silent", "--log", "matrix-test.log", "--requirements", "*-requirements.yaml", + using (var testContext = Context.Create(["--silent", "--log", "matrix-test.log", "--requirements", "*-requirements.yaml", "--tests", "*.trx", "--matrix", "matrix.md"])) { Program.Run(testContext); @@ -234,8 +234,8 @@ private static void RunTraceMatrixTest(Context context, DemaConsulting.TestResul else { test.Outcome = DemaConsulting.TestResults.TestOutcome.Failed; - test.ErrorMessage = exitCode != 0 - ? $"Program exited with code {exitCode}" + test.ErrorMessage = exitCode != 0 + ? $"Program exited with code {exitCode}" : "Matrix file not created"; context.WriteError($"✗ Trace Matrix Test - FAILED: {test.ErrorMessage}"); } @@ -277,7 +277,7 @@ private static void RunReportExportTest(Context context, DemaConsulting.TestResu { // Run the program with report export (using relative paths) int exitCode; - using (var testContext = Context.Create(["--silent", "--log", "export-test.log", "--requirements", "*-requirements.yaml", + using (var testContext = Context.Create(["--silent", "--log", "export-test.log", "--requirements", "*-requirements.yaml", "--report", "report.md"])) { Program.Run(testContext); @@ -304,8 +304,8 @@ private static void RunReportExportTest(Context context, DemaConsulting.TestResu else { test.Outcome = DemaConsulting.TestResults.TestOutcome.Failed; - test.ErrorMessage = exitCode != 0 - ? $"Program exited with code {exitCode}" + test.ErrorMessage = exitCode != 0 + ? $"Program exited with code {exitCode}" : "Report file not created"; context.WriteError($"✗ Report Export Test - FAILED: {test.ErrorMessage}"); } diff --git a/test/DemaConsulting.ReqStream.Tests/ProgramTests.cs b/test/DemaConsulting.ReqStream.Tests/ProgramTests.cs index c8b804e..afc2df7 100644 --- a/test/DemaConsulting.ReqStream.Tests/ProgramTests.cs +++ b/test/DemaConsulting.ReqStream.Tests/ProgramTests.cs @@ -111,7 +111,7 @@ public void Program_Run_WithHelpFlag_PrintsHelp() public void Program_Run_WithValidateFlag_RunsValidation() { var logFile = Path.Combine(_testDirectory, "validation.log"); - + // Run validation with silent and log flags using (var context = Context.Create(["--validate", "--silent", "--log", logFile])) { @@ -142,7 +142,7 @@ public void Program_Run_WithValidateAndResults_WritesResultsFile() { var logFile = Path.Combine(_testDirectory, "validation.log"); var resultsFile = Path.Combine(_testDirectory, "validation-results.trx"); - + // Run validation with results file using (var context = Context.Create(["--validate", "--silent", "--log", logFile, "--results", resultsFile])) { @@ -176,7 +176,7 @@ public void Program_Run_WithValidateAndJUnitResults_WritesJUnitFile() { var logFile = Path.Combine(_testDirectory, "validation.log"); var resultsFile = Path.Combine(_testDirectory, "validation-results.xml"); - + // Run validation with JUnit results file using (var context = Context.Create(["--validate", "--silent", "--log", logFile, "--results", resultsFile])) { @@ -503,7 +503,7 @@ public void Program_Run_WithEnforcementAndUnsatisfiedRequirements_Fails() Program.Run(context); Assert.AreEqual(1, context.ExitCode); - + // Verify error message includes the unsatisfied requirement var outputText = output.ToString(); Assert.Contains("Only 1 of 2 requirements are satisfied", outputText); diff --git a/test/DemaConsulting.ReqStream.Tests/TraceMatrixTests.cs b/test/DemaConsulting.ReqStream.Tests/TraceMatrixTests.cs index a349364..cd36af6 100644 --- a/test/DemaConsulting.ReqStream.Tests/TraceMatrixTests.cs +++ b/test/DemaConsulting.ReqStream.Tests/TraceMatrixTests.cs @@ -625,7 +625,7 @@ public void TraceMatrix_WithOnlyNotExecutedTests_TreatsAsNoTests() // Verify no tests are tracked var result1 = matrix.GetTestResult("Test_NotExecuted1"); Assert.AreEqual(0, result1.Executed, "Not-executed test should not be tracked"); - + var result2 = matrix.GetTestResult("Test_NotExecuted2"); Assert.AreEqual(0, result2.Executed, "Not-executed test should not be tracked"); From 7717547bf2d4b2049ea32e99e03a269c0d855308 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:34:40 +0000 Subject: [PATCH 3/8] Phase 2: Add build and lint scripts (build.sh, build.bat, lint.sh, lint.bat) Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- build.bat | 57 ++++++++++++++++++++++++++++++++++++++++++++++++ build.sh | 39 +++++++++++++++++++++++++++++++++ lint.bat | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ lint.sh | 48 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 209 insertions(+) create mode 100644 build.bat create mode 100755 build.sh create mode 100644 lint.bat create mode 100755 lint.sh diff --git a/build.bat b/build.bat new file mode 100644 index 0000000..e7b6570 --- /dev/null +++ b/build.bat @@ -0,0 +1,57 @@ +@echo off +REM Build, test, and package the ReqStream project + +echo === ReqStream Build Script === +echo. + +REM Restore dotnet tools +echo Restoring dotnet tools... +dotnet tool restore +if %errorlevel% neq 0 ( + echo X Failed to restore dotnet tools + exit /b 1 +) +echo + Dotnet tools restored +echo. + +REM Restore dependencies +echo Restoring dependencies... +dotnet restore +if %errorlevel% neq 0 ( + echo X Failed to restore dependencies + exit /b 1 +) +echo + Dependencies restored +echo. + +REM Build +echo Building... +dotnet build --no-restore --configuration Release +if %errorlevel% neq 0 ( + echo X Build failed + exit /b 1 +) +echo + Build succeeded +echo. + +REM Test +echo Running tests... +dotnet test --no-build --configuration Release --verbosity normal +if %errorlevel% neq 0 ( + echo X Tests failed + exit /b 1 +) +echo + Tests passed +echo. + +REM Package +echo Packaging... +dotnet pack --no-build --configuration Release +if %errorlevel% neq 0 ( + echo X Packaging failed + exit /b 1 +) +echo + Packaging succeeded +echo. + +echo === Build Complete === diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..3dfc25c --- /dev/null +++ b/build.sh @@ -0,0 +1,39 @@ +#!/bin/bash +# Build, test, and package the ReqStream project + +set -e + +echo "=== ReqStream Build Script ===" +echo "" + +# Restore dotnet tools +echo "Restoring dotnet tools..." +dotnet tool restore || { echo "✗ Failed to restore dotnet tools"; exit 1; } +echo "✓ Dotnet tools restored" +echo "" + +# Restore dependencies +echo "Restoring dependencies..." +dotnet restore || { echo "✗ Failed to restore dependencies"; exit 1; } +echo "✓ Dependencies restored" +echo "" + +# Build +echo "Building..." +dotnet build --no-restore --configuration Release || { echo "✗ Build failed"; exit 1; } +echo "✓ Build succeeded" +echo "" + +# Test +echo "Running tests..." +dotnet test --no-build --configuration Release --verbosity normal || { echo "✗ Tests failed"; exit 1; } +echo "✓ Tests passed" +echo "" + +# Package +echo "Packaging..." +dotnet pack --no-build --configuration Release || { echo "✗ Packaging failed"; exit 1; } +echo "✓ Packaging succeeded" +echo "" + +echo "=== Build Complete ===" diff --git a/lint.bat b/lint.bat new file mode 100644 index 0000000..651d9e9 --- /dev/null +++ b/lint.bat @@ -0,0 +1,65 @@ +@echo off +REM Run all linters on the ReqStream project + +echo === ReqStream Lint Script === +echo. + +REM Code format check +echo Checking code format... +dotnet format --verify-no-changes +if %errorlevel% neq 0 ( + echo X Code format check failed - run 'dotnet format' to fix + exit /b 1 +) +echo + Code format check passed +echo. + +REM Markdown lint +echo Checking markdown... +where markdownlint-cli2 >nul 2>nul +if %errorlevel% equ 0 ( + markdownlint-cli2 "**/*.md" + if %errorlevel% neq 0 ( + echo X Markdown lint failed + exit /b 1 + ) + echo + Markdown lint passed +) else ( + echo ! markdownlint-cli2 not found - skipping markdown lint + echo Install: npm install -g markdownlint-cli2 +) +echo. + +REM Spell check +echo Checking spelling... +where cspell >nul 2>nul +if %errorlevel% equ 0 ( + cspell --no-progress "**/*.md" "**/*.cs" + if %errorlevel% neq 0 ( + echo X Spell check failed + exit /b 1 + ) + echo + Spell check passed +) else ( + echo ! cspell not found - skipping spell check + echo Install: npm install -g cspell +) +echo. + +REM YAML lint +echo Checking YAML... +where yamllint >nul 2>nul +if %errorlevel% equ 0 ( + yamllint . + if %errorlevel% neq 0 ( + echo X YAML lint failed + exit /b 1 + ) + echo + YAML lint passed +) else ( + echo ! yamllint not found - skipping YAML lint + echo Install: pip install yamllint +) +echo. + +echo === Lint Complete === diff --git a/lint.sh b/lint.sh new file mode 100755 index 0000000..e079f92 --- /dev/null +++ b/lint.sh @@ -0,0 +1,48 @@ +#!/bin/bash +# Run all linters on the ReqStream project + +set -e + +echo "=== ReqStream Lint Script ===" +echo "" + +# Code format check +echo "Checking code format..." +dotnet format --verify-no-changes || { echo "✗ Code format check failed - run 'dotnet format' to fix"; exit 1; } +echo "✓ Code format check passed" +echo "" + +# Markdown lint +echo "Checking markdown..." +if command -v markdownlint-cli2 &> /dev/null; then + markdownlint-cli2 "**/*.md" || { echo "✗ Markdown lint failed"; exit 1; } + echo "✓ Markdown lint passed" +else + echo "⚠ markdownlint-cli2 not found - skipping markdown lint" + echo " Install: npm install -g markdownlint-cli2" +fi +echo "" + +# Spell check +echo "Checking spelling..." +if command -v cspell &> /dev/null; then + cspell --no-progress "**/*.md" "**/*.cs" || { echo "✗ Spell check failed"; exit 1; } + echo "✓ Spell check passed" +else + echo "⚠ cspell not found - skipping spell check" + echo " Install: npm install -g cspell" +fi +echo "" + +# YAML lint +echo "Checking YAML..." +if command -v yamllint &> /dev/null; then + yamllint . || { echo "✗ YAML lint failed"; exit 1; } + echo "✓ YAML lint passed" +else + echo "⚠ yamllint not found - skipping YAML lint" + echo " Install: pip install yamllint" +fi +echo "" + +echo "=== Lint Complete ===" From 0d7ac40dca3fefe70cd9561bb3fd36dc117e4509 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:35:59 +0000 Subject: [PATCH 4/8] Phase 3: Update configuration files and add VS Code tasks Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .cspell.json | 13 +++- .gitignore | 3 +- .markdownlint-cli2.jsonc | 20 +++++++ .markdownlint.json | 8 --- .vscode/tasks.json | 126 +++++++++++++++++++++++++++++++++++++++ 5 files changed, 160 insertions(+), 10 deletions(-) create mode 100644 .markdownlint-cli2.jsonc delete mode 100644 .markdownlint.json create mode 100644 .vscode/tasks.json diff --git a/.cspell.json b/.cspell.json index 2588b99..d4cda0b 100644 --- a/.cspell.json +++ b/.cspell.json @@ -43,7 +43,18 @@ "*.min.css", ".git", "package-lock.json", + "yarn.lock", "*.csproj", - "*.sln" + "*.sln", + "*.dll", + "*.exe", + "*.trx", + "*.spdx.json", + "AGENT_REPORT_*.md", + "*-review-report.md", + "CODE_QUALITY_REPORT.md", + "DOCUMENTATION_REVIEW.md", + "matrix.md", + "tracematrix.md" ] } diff --git a/.gitignore b/.gitignore index 59f7cdb..3f2eb69 100644 --- a/.gitignore +++ b/.gitignore @@ -17,7 +17,8 @@ bld/ .vs/ # Visual Studio Code directory -.vscode/ +.vscode/* +!.vscode/tasks.json # Rider directory .idea/ diff --git a/.markdownlint-cli2.jsonc b/.markdownlint-cli2.jsonc new file mode 100644 index 0000000..ab71277 --- /dev/null +++ b/.markdownlint-cli2.jsonc @@ -0,0 +1,20 @@ +{ + "config": { + "default": true, + "MD003": { "style": "atx" }, + "MD007": { "indent": 2 }, + "MD013": { "line_length": 120 }, + "MD033": false, + "MD041": false + }, + "ignores": [ + "node_modules/**", + "**/node_modules/**", + "AGENT_REPORT_*.md", + "*-review-report.md", + "CODE_QUALITY_REPORT.md", + "DOCUMENTATION_REVIEW.md", + "matrix.md", + "tracematrix.md" + ] +} diff --git a/.markdownlint.json b/.markdownlint.json deleted file mode 100644 index e3884ab..0000000 --- a/.markdownlint.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "default": true, - "MD003": { "style": "atx" }, - "MD007": { "indent": 2 }, - "MD013": { "line_length": 120 }, - "MD033": false, - "MD041": false -} diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 0000000..63052c6 --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,126 @@ +{ + "version": "2.0.0", + "tasks": [ + { + "label": "build", + "command": "dotnet", + "type": "process", + "args": [ + "build", + "${workspaceFolder}/DemaConsulting.ReqStream.sln", + "/property:GenerateFullPaths=true", + "/consoleloggerparameters:NoSummary;ForceNoAlign" + ], + "problemMatcher": "$msCompile", + "group": { + "kind": "build", + "isDefault": true + } + }, + { + "label": "test", + "command": "dotnet", + "type": "process", + "args": [ + "test", + "${workspaceFolder}/DemaConsulting.ReqStream.sln", + "--no-build", + "--verbosity", + "normal" + ], + "problemMatcher": "$msCompile", + "group": { + "kind": "test", + "isDefault": true + }, + "dependsOn": "build" + }, + { + "label": "clean", + "command": "dotnet", + "type": "process", + "args": [ + "clean", + "${workspaceFolder}/DemaConsulting.ReqStream.sln" + ], + "problemMatcher": "$msCompile" + }, + { + "label": "restore", + "command": "dotnet", + "type": "process", + "args": [ + "restore", + "${workspaceFolder}/DemaConsulting.ReqStream.sln" + ], + "problemMatcher": "$msCompile" + }, + { + "label": "format", + "command": "dotnet", + "type": "process", + "args": [ + "format", + "${workspaceFolder}/DemaConsulting.ReqStream.sln" + ], + "problemMatcher": [] + }, + { + "label": "lint", + "command": "bash", + "type": "shell", + "args": [ + "${workspaceFolder}/lint.sh" + ], + "windows": { + "command": "${workspaceFolder}/lint.bat" + }, + "problemMatcher": [] + }, + { + "label": "validate", + "command": "dotnet", + "type": "process", + "args": [ + "run", + "--project", + "${workspaceFolder}/src/DemaConsulting.ReqStream/DemaConsulting.ReqStream.csproj", + "--no-build", + "--", + "--validate" + ], + "problemMatcher": [], + "dependsOn": "build" + }, + { + "label": "verify-requirements", + "command": "dotnet", + "type": "process", + "args": [ + "run", + "--project", + "${workspaceFolder}/src/DemaConsulting.ReqStream/DemaConsulting.ReqStream.csproj", + "--no-build", + "--", + "--requirements", + "${workspaceFolder}/requirements.yaml", + "--tests", + "${workspaceFolder}/test/**/TestResults/*.trx", + "--enforce" + ], + "problemMatcher": [], + "dependsOn": "test" + }, + { + "label": "build-all", + "dependsOn": [ + "restore", + "build", + "test", + "format", + "lint" + ], + "problemMatcher": [] + } + ] +} From 7171288fc581be18fdcf1eb68a10dd789f9e6e71 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:40:13 +0000 Subject: [PATCH 5/8] Phase 4: Add CHANGELOG.md, convert to .slnx format, remove dates from ARCHITECTURE.md Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .cspell.json | 1 + .vscode/tasks.json | 10 +++--- AGENTS.md | 2 +- ARCHITECTURE.md | 4 --- CHANGELOG.md | 67 +++++++++++++++++++++++++++++++++++ DemaConsulting.ReqStream.sln | 28 --------------- DemaConsulting.ReqStream.slnx | 12 +++++++ 7 files changed, 86 insertions(+), 38 deletions(-) create mode 100644 CHANGELOG.md delete mode 100644 DemaConsulting.ReqStream.sln create mode 100644 DemaConsulting.ReqStream.slnx diff --git a/.cspell.json b/.cspell.json index d4cda0b..460c663 100644 --- a/.cspell.json +++ b/.cspell.json @@ -46,6 +46,7 @@ "yarn.lock", "*.csproj", "*.sln", + "*.slnx", "*.dll", "*.exe", "*.trx", diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 63052c6..efa6951 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -7,7 +7,7 @@ "type": "process", "args": [ "build", - "${workspaceFolder}/DemaConsulting.ReqStream.sln", + "${workspaceFolder}/DemaConsulting.ReqStream.slnx", "/property:GenerateFullPaths=true", "/consoleloggerparameters:NoSummary;ForceNoAlign" ], @@ -23,7 +23,7 @@ "type": "process", "args": [ "test", - "${workspaceFolder}/DemaConsulting.ReqStream.sln", + "${workspaceFolder}/DemaConsulting.ReqStream.slnx", "--no-build", "--verbosity", "normal" @@ -41,7 +41,7 @@ "type": "process", "args": [ "clean", - "${workspaceFolder}/DemaConsulting.ReqStream.sln" + "${workspaceFolder}/DemaConsulting.ReqStream.slnx" ], "problemMatcher": "$msCompile" }, @@ -51,7 +51,7 @@ "type": "process", "args": [ "restore", - "${workspaceFolder}/DemaConsulting.ReqStream.sln" + "${workspaceFolder}/DemaConsulting.ReqStream.slnx" ], "problemMatcher": "$msCompile" }, @@ -61,7 +61,7 @@ "type": "process", "args": [ "format", - "${workspaceFolder}/DemaConsulting.ReqStream.sln" + "${workspaceFolder}/DemaConsulting.ReqStream.slnx" ], "problemMatcher": [] }, diff --git a/AGENTS.md b/AGENTS.md index 358499c..d46223f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -55,7 +55,7 @@ ReqStream/ - **`.cspell.json`**: Contains spell-checking configuration and custom dictionary - **`.markdownlint.json`**: Markdown linting rules - **`.yamllint.yaml`**: YAML linting rules -- **`DemaConsulting.ReqStream.sln`**: Solution file containing all projects +- **`DemaConsulting.ReqStream.slnx`**: Solution file containing all projects (XML format) - **`ARCHITECTURE.md`**: Comprehensive guide to the tool's architecture and internal design ## Testing Guidelines diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index b869324..11a586d 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -973,8 +973,4 @@ private void ReadFile(string path) --- -**Document Version**: 1.0 - -**Last Updated**: 2025-01-11 - For questions or suggestions about this architecture document, please open an issue or submit a pull request. diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..b34ecf4 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,67 @@ +# Changelog + +All notable changes to the ReqStream project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## [Unreleased] + +### Added + +- Build scripts for convenient development (`build.sh`, `build.bat`) +- Lint scripts for code quality checks (`lint.sh`, `lint.bat`) +- VS Code tasks for improved developer experience (`.vscode/tasks.json`) +- Markdownlint configuration with ignore patterns (`.markdownlint-cli2.jsonc`) +- Enhanced spell-check configuration with binary file exclusions (`.cspell.json`) +- CHANGELOG.md following Keep a Changelog format + +### Changed + +- Converted solution file from `.sln` to `.slnx` format (XML-based modern format) +- Updated `.gitignore` to exclude agent-generated reports while tracking VS Code tasks +- Enhanced build workflow to include integration test results in documentation build +- Updated all tooling references to use `.slnx` format +- Removed version and date metadata from ARCHITECTURE.md (should reflect current repo state) + +### Changed + +- Updated `.gitignore` to exclude agent-generated reports while tracking VS Code tasks +- Fixed ARCHITECTURE.md date (changed from future date to correct date) +- Enhanced build workflow to include integration test results in documentation build + +### Fixed + +- Code formatting issues (24 whitespace and charset violations) +- Integration test results now properly included in documentation generation + +## [1.0.0] - Initial Release + +### Added + +- Requirements management tool for YAML files +- Command-line interface with support for: + - `--version`: Display version information + - `--help`: Display usage help + - `--validate`: Run self-validation tests + - `--requirements`: Specify requirements YAML file + - `--tests`: Specify test results (TRX format) + - `--report`: Generate requirements report + - `--matrix`: Generate trace matrix + - `--justifications`: Export justifications + - `--enforce`: Enforce all requirements are satisfied + - `--silent`: Suppress normal output + - `--log`: Write output to log file +- Support for multiple .NET target frameworks (net8.0, net9.0, net10.0) +- Comprehensive test suite with 117 unit tests +- Self-validation tests demonstrating real-world usage +- Integration tests across multiple platforms and .NET versions +- GitHub Actions CI/CD pipeline +- CodeQL security analysis +- SonarCloud quality analysis +- Documentation generation with Pandoc and Weasyprint +- Requirements traceability with test source linking +- NuGet package distribution + +[Unreleased]: https://github.com/demaconsulting/ReqStream/compare/v1.0.0...HEAD +[1.0.0]: https://github.com/demaconsulting/ReqStream/releases/tag/v1.0.0 diff --git a/DemaConsulting.ReqStream.sln b/DemaConsulting.ReqStream.sln deleted file mode 100644 index ab0fa10..0000000 --- a/DemaConsulting.ReqStream.sln +++ /dev/null @@ -1,28 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.0.31903.59 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DemaConsulting.ReqStream", "src\DemaConsulting.ReqStream\DemaConsulting.ReqStream.csproj", "{51C8C53D-80DF-4C6B-993C-8E4E27B4B3EB}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DemaConsulting.ReqStream.Tests", "test\DemaConsulting.ReqStream.Tests\DemaConsulting.ReqStream.Tests.csproj", "{B251BAE3-0391-44AA-90E9-D30A8F339525}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {51C8C53D-80DF-4C6B-993C-8E4E27B4B3EB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {51C8C53D-80DF-4C6B-993C-8E4E27B4B3EB}.Debug|Any CPU.Build.0 = Debug|Any CPU - {51C8C53D-80DF-4C6B-993C-8E4E27B4B3EB}.Release|Any CPU.ActiveCfg = Release|Any CPU - {51C8C53D-80DF-4C6B-993C-8E4E27B4B3EB}.Release|Any CPU.Build.0 = Release|Any CPU - {B251BAE3-0391-44AA-90E9-D30A8F339525}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {B251BAE3-0391-44AA-90E9-D30A8F339525}.Debug|Any CPU.Build.0 = Debug|Any CPU - {B251BAE3-0391-44AA-90E9-D30A8F339525}.Release|Any CPU.ActiveCfg = Release|Any CPU - {B251BAE3-0391-44AA-90E9-D30A8F339525}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/DemaConsulting.ReqStream.slnx b/DemaConsulting.ReqStream.slnx new file mode 100644 index 0000000..1d7051c --- /dev/null +++ b/DemaConsulting.ReqStream.slnx @@ -0,0 +1,12 @@ + + + + + + + + + + + + From 57addc21b028b6679ee79e1e6d343e9a4b2070c9 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:44:37 +0000 Subject: [PATCH 6/8] Remove CHANGELOG.md - changes documented by build notes Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- CHANGELOG.md | 67 ---------------------------------------------------- 1 file changed, 67 deletions(-) delete mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index b34ecf4..0000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,67 +0,0 @@ -# Changelog - -All notable changes to the ReqStream project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [Unreleased] - -### Added - -- Build scripts for convenient development (`build.sh`, `build.bat`) -- Lint scripts for code quality checks (`lint.sh`, `lint.bat`) -- VS Code tasks for improved developer experience (`.vscode/tasks.json`) -- Markdownlint configuration with ignore patterns (`.markdownlint-cli2.jsonc`) -- Enhanced spell-check configuration with binary file exclusions (`.cspell.json`) -- CHANGELOG.md following Keep a Changelog format - -### Changed - -- Converted solution file from `.sln` to `.slnx` format (XML-based modern format) -- Updated `.gitignore` to exclude agent-generated reports while tracking VS Code tasks -- Enhanced build workflow to include integration test results in documentation build -- Updated all tooling references to use `.slnx` format -- Removed version and date metadata from ARCHITECTURE.md (should reflect current repo state) - -### Changed - -- Updated `.gitignore` to exclude agent-generated reports while tracking VS Code tasks -- Fixed ARCHITECTURE.md date (changed from future date to correct date) -- Enhanced build workflow to include integration test results in documentation build - -### Fixed - -- Code formatting issues (24 whitespace and charset violations) -- Integration test results now properly included in documentation generation - -## [1.0.0] - Initial Release - -### Added - -- Requirements management tool for YAML files -- Command-line interface with support for: - - `--version`: Display version information - - `--help`: Display usage help - - `--validate`: Run self-validation tests - - `--requirements`: Specify requirements YAML file - - `--tests`: Specify test results (TRX format) - - `--report`: Generate requirements report - - `--matrix`: Generate trace matrix - - `--justifications`: Export justifications - - `--enforce`: Enforce all requirements are satisfied - - `--silent`: Suppress normal output - - `--log`: Write output to log file -- Support for multiple .NET target frameworks (net8.0, net9.0, net10.0) -- Comprehensive test suite with 117 unit tests -- Self-validation tests demonstrating real-world usage -- Integration tests across multiple platforms and .NET versions -- GitHub Actions CI/CD pipeline -- CodeQL security analysis -- SonarCloud quality analysis -- Documentation generation with Pandoc and Weasyprint -- Requirements traceability with test source linking -- NuGet package distribution - -[Unreleased]: https://github.com/demaconsulting/ReqStream/compare/v1.0.0...HEAD -[1.0.0]: https://github.com/demaconsulting/ReqStream/releases/tag/v1.0.0 From 2f44ae2f7e1236d8b45f8dbd7789ea72ab636909 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 19:55:38 +0000 Subject: [PATCH 7/8] Fix review feedback: simplify scripts, remove bogus patterns, fix duplicate download step Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .cspell.json | 7 +--- .github/workflows/build.yaml | 7 ---- .gitignore | 5 --- .markdownlint-cli2.jsonc | 8 +---- build.bat | 63 ++++++-------------------------- build.sh | 44 ++++++----------------- lint.bat | 69 +++++++----------------------------- lint.sh | 54 +++++++--------------------- 8 files changed, 47 insertions(+), 210 deletions(-) diff --git a/.cspell.json b/.cspell.json index 460c663..2216fe8 100644 --- a/.cspell.json +++ b/.cspell.json @@ -51,11 +51,6 @@ "*.exe", "*.trx", "*.spdx.json", - "AGENT_REPORT_*.md", - "*-review-report.md", - "CODE_QUALITY_REPORT.md", - "DOCUMENTATION_REVIEW.md", - "matrix.md", - "tracematrix.md" + "AGENT_REPORT_*.md" ] } diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8584530..f2c75f9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -271,13 +271,6 @@ jobs: pattern: '*test-results*' continue-on-error: true - - name: Download integration test results - uses: actions/download-artifact@v7 - with: - path: test-results - pattern: 'integration-test-results-*' - continue-on-error: true - - name: Download package uses: actions/download-artifact@v7 with: diff --git a/.gitignore b/.gitignore index 3f2eb69..58b8daf 100644 --- a/.gitignore +++ b/.gitignore @@ -129,8 +129,3 @@ docs/*.pdf # Agent-generated reports (should not be committed) AGENT_REPORT_*.md -*-review-report.md -CODE_QUALITY_REPORT.md -DOCUMENTATION_REVIEW.md -matrix.md -tracematrix.md diff --git a/.markdownlint-cli2.jsonc b/.markdownlint-cli2.jsonc index ab71277..a480857 100644 --- a/.markdownlint-cli2.jsonc +++ b/.markdownlint-cli2.jsonc @@ -9,12 +9,6 @@ }, "ignores": [ "node_modules/**", - "**/node_modules/**", - "AGENT_REPORT_*.md", - "*-review-report.md", - "CODE_QUALITY_REPORT.md", - "DOCUMENTATION_REVIEW.md", - "matrix.md", - "tracematrix.md" + "AGENT_REPORT_*.md" ] } diff --git a/build.bat b/build.bat index e7b6570..88b51d0 100644 --- a/build.bat +++ b/build.bat @@ -1,57 +1,16 @@ @echo off -REM Build, test, and package the ReqStream project +REM Build and test ReqStream (Windows) -echo === ReqStream Build Script === -echo. +echo Building ReqStream... +dotnet build --configuration Release +if %errorlevel% neq 0 exit /b %errorlevel% -REM Restore dotnet tools -echo Restoring dotnet tools... -dotnet tool restore -if %errorlevel% neq 0 ( - echo X Failed to restore dotnet tools - exit /b 1 -) -echo + Dotnet tools restored -echo. +echo Running unit tests... +dotnet test --configuration Release +if %errorlevel% neq 0 exit /b %errorlevel% -REM Restore dependencies -echo Restoring dependencies... -dotnet restore -if %errorlevel% neq 0 ( - echo X Failed to restore dependencies - exit /b 1 -) -echo + Dependencies restored -echo. +echo Running self-validation... +dotnet run --project src/DemaConsulting.ReqStream --configuration Release --framework net10.0 --no-build -- --validate +if %errorlevel% neq 0 exit /b %errorlevel% -REM Build -echo Building... -dotnet build --no-restore --configuration Release -if %errorlevel% neq 0 ( - echo X Build failed - exit /b 1 -) -echo + Build succeeded -echo. - -REM Test -echo Running tests... -dotnet test --no-build --configuration Release --verbosity normal -if %errorlevel% neq 0 ( - echo X Tests failed - exit /b 1 -) -echo + Tests passed -echo. - -REM Package -echo Packaging... -dotnet pack --no-build --configuration Release -if %errorlevel% neq 0 ( - echo X Packaging failed - exit /b 1 -) -echo + Packaging succeeded -echo. - -echo === Build Complete === +echo Build, tests, and validation completed successfully! diff --git a/build.sh b/build.sh index 3dfc25c..be5a016 100755 --- a/build.sh +++ b/build.sh @@ -1,39 +1,15 @@ -#!/bin/bash -# Build, test, and package the ReqStream project +#!/usr/bin/env bash +# Build and test ReqStream -set -e +set -e # Exit on error -echo "=== ReqStream Build Script ===" -echo "" +echo "🔧 Building ReqStream..." +dotnet build --configuration Release -# Restore dotnet tools -echo "Restoring dotnet tools..." -dotnet tool restore || { echo "✗ Failed to restore dotnet tools"; exit 1; } -echo "✓ Dotnet tools restored" -echo "" +echo "🧪 Running unit tests..." +dotnet test --configuration Release -# Restore dependencies -echo "Restoring dependencies..." -dotnet restore || { echo "✗ Failed to restore dependencies"; exit 1; } -echo "✓ Dependencies restored" -echo "" +echo "✅ Running self-validation..." +dotnet run --project src/DemaConsulting.ReqStream --configuration Release --framework net10.0 --no-build -- --validate -# Build -echo "Building..." -dotnet build --no-restore --configuration Release || { echo "✗ Build failed"; exit 1; } -echo "✓ Build succeeded" -echo "" - -# Test -echo "Running tests..." -dotnet test --no-build --configuration Release --verbosity normal || { echo "✗ Tests failed"; exit 1; } -echo "✓ Tests passed" -echo "" - -# Package -echo "Packaging..." -dotnet pack --no-build --configuration Release || { echo "✗ Packaging failed"; exit 1; } -echo "✓ Packaging succeeded" -echo "" - -echo "=== Build Complete ===" +echo "✨ Build, tests, and validation completed successfully!" diff --git a/lint.bat b/lint.bat index 651d9e9..6c22bdc 100644 --- a/lint.bat +++ b/lint.bat @@ -1,65 +1,20 @@ @echo off -REM Run all linters on the ReqStream project +REM Run all linters for ReqStream (Windows) -echo === ReqStream Lint Script === -echo. - -REM Code format check -echo Checking code format... -dotnet format --verify-no-changes -if %errorlevel% neq 0 ( - echo X Code format check failed - run 'dotnet format' to fix - exit /b 1 -) -echo + Code format check passed -echo. - -REM Markdown lint echo Checking markdown... -where markdownlint-cli2 >nul 2>nul -if %errorlevel% equ 0 ( - markdownlint-cli2 "**/*.md" - if %errorlevel% neq 0 ( - echo X Markdown lint failed - exit /b 1 - ) - echo + Markdown lint passed -) else ( - echo ! markdownlint-cli2 not found - skipping markdown lint - echo Install: npm install -g markdownlint-cli2 -) -echo. +call npx markdownlint-cli2 "**/*.md" +if %errorlevel% neq 0 exit /b %errorlevel% -REM Spell check echo Checking spelling... -where cspell >nul 2>nul -if %errorlevel% equ 0 ( - cspell --no-progress "**/*.md" "**/*.cs" - if %errorlevel% neq 0 ( - echo X Spell check failed - exit /b 1 - ) - echo + Spell check passed -) else ( - echo ! cspell not found - skipping spell check - echo Install: npm install -g cspell -) -echo. +call npx cspell "**/*.{cs,md,json,yaml,yml}" --no-progress +if %errorlevel% neq 0 exit /b %errorlevel% -REM YAML lint echo Checking YAML... -where yamllint >nul 2>nul -if %errorlevel% equ 0 ( - yamllint . - if %errorlevel% neq 0 ( - echo X YAML lint failed - exit /b 1 - ) - echo + YAML lint passed -) else ( - echo ! yamllint not found - skipping YAML lint - echo Install: pip install yamllint -) -echo. +call yamllint -c .yamllint.yaml . +if %errorlevel% neq 0 exit /b %errorlevel% + +echo Checking code formatting... +dotnet format --verify-no-changes +if %errorlevel% neq 0 exit /b %errorlevel% -echo === Lint Complete === +echo All linting passed! diff --git a/lint.sh b/lint.sh index e079f92..59ab732 100755 --- a/lint.sh +++ b/lint.sh @@ -1,48 +1,18 @@ -#!/bin/bash -# Run all linters on the ReqStream project +#!/usr/bin/env bash +# Run all linters for ReqStream -set -e +set -e # Exit on error -echo "=== ReqStream Lint Script ===" -echo "" +echo "📝 Checking markdown..." +npx markdownlint-cli2 "**/*.md" -# Code format check -echo "Checking code format..." -dotnet format --verify-no-changes || { echo "✗ Code format check failed - run 'dotnet format' to fix"; exit 1; } -echo "✓ Code format check passed" -echo "" +echo "🔤 Checking spelling..." +npx cspell "**/*.{cs,md,json,yaml,yml}" --no-progress -# Markdown lint -echo "Checking markdown..." -if command -v markdownlint-cli2 &> /dev/null; then - markdownlint-cli2 "**/*.md" || { echo "✗ Markdown lint failed"; exit 1; } - echo "✓ Markdown lint passed" -else - echo "⚠ markdownlint-cli2 not found - skipping markdown lint" - echo " Install: npm install -g markdownlint-cli2" -fi -echo "" +echo "📋 Checking YAML..." +yamllint -c .yamllint.yaml . -# Spell check -echo "Checking spelling..." -if command -v cspell &> /dev/null; then - cspell --no-progress "**/*.md" "**/*.cs" || { echo "✗ Spell check failed"; exit 1; } - echo "✓ Spell check passed" -else - echo "⚠ cspell not found - skipping spell check" - echo " Install: npm install -g cspell" -fi -echo "" +echo "🎨 Checking code formatting..." +dotnet format --verify-no-changes -# YAML lint -echo "Checking YAML..." -if command -v yamllint &> /dev/null; then - yamllint . || { echo "✗ YAML lint failed"; exit 1; } - echo "✓ YAML lint passed" -else - echo "⚠ yamllint not found - skipping YAML lint" - echo " Install: pip install yamllint" -fi -echo "" - -echo "=== Lint Complete ===" +echo "✨ All linting passed!" From a3d38a353481e4f7e9ed2ab7ec844a60b1542019 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 11 Feb 2026 20:04:47 +0000 Subject: [PATCH 8/8] Fix lint issue: Add 'slnx' to spell check dictionary Co-authored-by: Malcolmnixon <1863707+Malcolmnixon@users.noreply.github.com> --- .cspell.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.cspell.json b/.cspell.json index 2216fe8..3d842cc 100644 --- a/.cspell.json +++ b/.cspell.json @@ -33,7 +33,8 @@ "CodeQL", "SonarMark", "SarifMark", - "buildnotes" + "buildnotes", + "slnx" ], "ignorePaths": [ "node_modules",