feat: semantic state machines (Moore/Mealy), robustness tests, and docs - #27
Merged
Conversation
working on #24 Add semantic utilities and tests for pattern matching functionality
Refactored PatternMatches<T> to be thread-safe by introducing a _syncRoot lock and updating HasMatch() and Next() methods. Ensured Matched event is invoked outside the lock to prevent deadlocks. Added a unit test to verify safe concurrent access.
- Use relative path for RunSettingsFilePath in SemanticTests.csproj - Add all states explicitly in Moore state machine tests - Update coverlet.runsettings: fix friendlyName, remove module exclusion, set format to cobertura
…itional tests for overlap and repeated patterns
Adds shared runtime internals for state-machine processing, expands docs, and updates test/benchmark dependencies. Closes #23 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Introduces typed and untyped fluent Moore builders, transition safety checks, runtime processing hardening, and extensive robustness tests. Closes #24 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adds typed and untyped Mealy machines with fluent transition/output DSL, safety validations, and broad scenario coverage tests. Closes #25 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adds concise usage snippets for SlidingWindow, Moore, and Mealy (typed and untyped) plus pointers to robust test scenarios. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Closed
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #27 +/- ##
==========================================
+ Coverage 95.95% 97.19% +1.23%
==========================================
Files 7 17 +10
Lines 99 392 +293
Branches 20 38 +18
==========================================
+ Hits 95 381 +286
- Misses 2 6 +4
- Partials 2 5 +3 ☔ View full report in Codecov by Harness. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Key changes
From(...).On(...).GoTo(...).Emits(...)Moore<TState, TInput>Mealy<TState, TInput, TOutput>Validation
dotnet test SemanticTests/SemanticTests.csprojpassed (57/57)dotnet build SemanticBenchmarks/SemanticBenchmarks.csprojpassedCloses #23
Closes #24
Closes #25