Commit graph

695 commits

Author SHA1 Message Date
lukhipolito-nexxbiz 90af851962
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/FileUploadWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:15:39 +01:00
lukhipolito-nexxbiz 859a14ede2
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/BlockedFileExtensionWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:14:52 +01:00
lukhipolito-nexxbiz 2f9d6c1ec3
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/BasicHttpEndpointWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:14:39 +01:00
lukhipolito-nexxbiz f023e1f994
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/README.md
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:14:03 +01:00
lukhipolito-nexxbiz c791843860
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointRouteParametersTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:13:49 +01:00
lukhipolito-nexxbiz d8b929a5bd
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/QueryStringAndHeadersWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:13:38 +01:00
lukhipolito-nexxbiz 1f0aa37780
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/MultipleHttpMethodsWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:13:28 +01:00
lukhipolito-nexxbiz 9f0220e088
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/FormDataWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 16:13:17 +01:00
lucas.hipolito 0074061990 fixing build after merge 2025-12-03 15:31:33 +01:00
lucas.hipolito 2f93f498b4 Merge remote-tracking branch 'origin/feat/tests-http-endpoint' into feat/tests-http-endpoint 2025-12-03 15:30:20 +01:00
lucas.hipolito 7184336f8e PR comments 2025-12-03 15:30:17 +01:00
lukhipolito-nexxbiz fc14e99ed4
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 15:30:00 +01:00
lukhipolito-nexxbiz 536e908898
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 14:33:14 +01:00
lukhipolito-nexxbiz d77f73d1dc
Update test/unit/Elsa.Activities.UnitTests/Http/HttpEndpointTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 14:08:55 +01:00
lukhipolito-nexxbiz eaac09dfd6
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/README.md
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 14:08:21 +01:00
lucas.hipolito 3ddd6bb1cf Merge remote-tracking branch 'origin/feat/tests-http-endpoint' into feat/tests-http-endpoint 2025-12-03 11:48:56 +01:00
lucas.hipolito 570b0d4678 Removed unnecessary tests, small refactors for readability +organization 2025-12-03 11:48:53 +01:00
lukhipolito-nexxbiz 1fe6e0e420
Update test/unit/Elsa.Activities.UnitTests/Http/HttpEndpointTests.cs
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
2025-12-03 11:38:29 +01:00
lucas.hipolito 9e7b04b48d Merge remote-tracking branch 'origin/feat/tests-http-endpoint' into feat/tests-http-endpoint 2025-12-03 11:25:10 +01:00
lukhipolito-nexxbiz c4f1fcdef4
Merge pull request #7126 from elsa-workflows/copilot/sub-pr-7125
Remove test that validates web server behavior rather than Elsa functionality
2025-12-03 11:24:36 +01:00
lucas.hipolito bbf9378d83 Merge remote-tracking branch 'origin/feat/tests-http-endpoint' into feat/tests-http-endpoint 2025-12-03 11:22:06 +01:00
lucas.hipolito ad9bc2ef70 Removing ambiguous assertions 2025-12-03 11:20:51 +01:00
lukhipolito-nexxbiz e3149ea3c2
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 11:19:57 +01:00
lukhipolito-nexxbiz a87cbe34a2
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointSecurityAndEdgeCasesTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 11:18:21 +01:00
lukhipolito-nexxbiz 46004b33c4
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointSecurityAndEdgeCasesTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 11:18:06 +01:00
lukhipolito-nexxbiz 4712782e6d
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointQueryStringAndHeadersTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 11:17:21 +01:00
lukhipolito-nexxbiz 466f62f016
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/FormDataWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 11:06:34 +01:00
lukhipolito-nexxbiz b0ee28008e
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/RouteParametersWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-03 08:20:27 +01:00
copilot-swe-agent[bot] 0a337fe251 Remove HttpEndpoint_ExtremelyLongPath_HandlesGracefully test per reviewer feedback
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
2025-12-02 17:23:04 +00:00
lucas.hipolito eb05233f36 small QoL improvements 2025-12-02 17:19:25 +01:00
lukhipolito-nexxbiz bacca3f890
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointSecurityAndEdgeCasesTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 16:51:43 +01:00
lukhipolito-nexxbiz e281ff229a
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/HttpEndpointQueryStringAndHeadersTests.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 16:50:42 +01:00
lucas.hipolito 7091d07dc3 Merge remote-tracking branch 'origin/feat/tests-http-endpoint' into feat/tests-http-endpoint 2025-12-02 15:36:05 +01:00
lucas.hipolito f8d46d7afe PR improvements. More DRY, less clutter 2025-12-02 15:35:41 +01:00
lukhipolito-nexxbiz e3645566e4
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/FileUploadWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 15:05:17 +01:00
lukhipolito-nexxbiz 3c3154a7ee
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/FormDataWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 13:42:09 +01:00
lukhipolito-nexxbiz 65159e2665
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/RouteParametersWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 13:02:59 +01:00
lukhipolito-nexxbiz a3b46d1419
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/Workflows/RouteParametersWorkflow.cs
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 13:01:02 +01:00
lukhipolito-nexxbiz c62a882ad8
Update test/component/Elsa.Workflows.ComponentTests/Scenarios/Activities/Http/README.md
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 13:00:46 +01:00
lucas.hipolito 656208bbf7 Http endpoint unit, integration and component tests 2025-12-02 12:03:01 +01:00
Sipke Schoorstra 7a66926f16
Add unit and integration tests for ParallelForEach activity covering behavior with different item types, fault handling, and scenario-specific conditions (#7120)
* Add unit and integration tests for `ParallelForEach` activity covering behavior with different item types, fault handling, and scenario-specific conditions

* Replace `Array.Empty<string>()` with `[]` in `ParallelForEachTests` to simplify syntax.
2025-11-27 20:58:58 +01:00
Sipke Schoorstra e3a8e533c8
Add unit tests for Correlate activity and enhance ActivityTestFixture execution functionality (#7119)
* Add unit tests for `Correlate` activity and enhance `ActivityTestFixture` execution functionality

- Introduced `CorrelateTests` to validate correlation ID handling with string literals, inputs, and functions.
- Extended `ActivityTestFixture` with new `ExecuteAsync(ActivityExecutionContext)` overload for improved test execution customization.

* Update src/common/Elsa.Testing.Shared/ActivityTestFixture.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-27 20:57:48 +01:00
Sipke Schoorstra e261a91127
Add unit and integration tests for FlowDecision activity to validate branching and nested workflow logic (#7117)
* Add unit and integration tests for `FlowDecision` activity to validate branching and nested workflow logic

- Included integration tests covering `FlowDecision` behavior for conditions, nested decisions, single-path scenarios, and path convergence in flowcharts.
- Added unit tests to verify correctness of outcomes, default behavior, and condition evaluation logic.

* Refactor `FlowDecisionTests` to improve parameterized test coverage, streamline assertions, and enhance test organization by introducing reusable data providers.

* Add `[Collection("FlowchartTests")]` annotation to `FlowDecisionTests` to improve test grouping and execution consistency.
2025-11-27 20:57:38 +01:00
Sipke Schoorstra d608b9de14
Adds unit tests for SetName activity (#7116)
* Add unit tests for `SetName` activity to validate workflow name assignment and edge case handling

* Remove unused `Elsa.Workflows.Activities` import from `SetNameTests`.
2025-11-27 20:52:21 +01:00
Sipke Schoorstra 02f53c3ef2
Add unit tests for NotFoundActivity to validate exception behavior (#7115)
- Introduced `NotFoundActivityTests` to cover scenarios of missing activity types and versions.
- Added tests to assert `ActivityNotFoundException` handling and inclusion of type name and version in exception messages.
2025-11-27 20:52:07 +01:00
Sipke Schoorstra 4ee8f6912d
Add unit and integration tests for the Finish activity to validate termination behavior (#7110) (#7114)
* Add unit and integration tests for the `Finish` activity to validate termination behavior (#7110)

- Added `FinishInSequenceWorkflow` to test `Finish` activity in a sequence workflow configuration.
- Introduced integration tests (`FinishTests`) to confirm `Finish` terminates workflows and skips subsequent activities.
- Developed unit tests to verify activity completion and workflow status transitions to `Finished`.

* Update test/integration/Elsa.Activities.IntegrationTests/Primitives/Workflows/FinishInSequenceWorkflow.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update test/integration/Elsa.Activities.IntegrationTests/Primitives/Workflows/FinishInSequenceWorkflow.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Add `Finish` activity unit test to verify ITerminalNode implementation

* Add code coverage report generation and GitHub Pages deployment workflow

- Removed unused `tempvalidator` project and its associated files.
- Updated GitHub Actions workflow to include steps for generating code coverage reports in HTML format using `dotnet-reportgenerator-globaltool`.
- Added deployment of coverage reports to GitHub Pages for the `main` branch.
- Updated `.gitignore` to exclude test results and artifacts.

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-27 20:51:59 +01:00
Sipke Schoorstra 8f35cab2ad
Add unit and integration tests for Fault activity to validate fault propagation behavior (#7113)
- Introduced multiple workflows (`FaultWorkflow`, `FaultWithDefaultsWorkflow`, `FaultViaFactoryWorkflow`, `FaultInSequenceWorkflow`) to test fault scenarios.
- Added `FaultTests` to verify fault propagation, stopping subsequent activities, and validating default, custom, and factory-configured fault behaviors.
- Included unit tests to ensure `FaultException` is thrown correctly with all properties set and default values applied when inputs are null.
2025-11-27 20:51:50 +01:00
Sipke Schoorstra 74f06914de
Add unit tests for ReadLine activity (#7110) (#7112)
* Add unit tests for `ReadLine` activity (#7110)

- Implemented `ReadLineTests` to verify the behavior of the `ReadLine` activity.
- Added scenarios for reading input, stream provider usage, and successful completion.
- Refactored `ExecuteAsync` helper to streamline test execution with mock dependencies.

* Enhance `ReadLine` activity tests with additional scenarios: validate null handling, default provider usage, and completion status assertions.
2025-11-27 20:51:41 +01:00
Sipke Schoorstra 39dae54604
Add integration and unit tests for Start activity across different workflow scenarios (#7111)
- Introduced three test workflows:
  - `StartInFlowchartAsExplicitStartWorkflow`: Verifies the explicit `Start` activity in a flowchart as a starting point.
  - `StartInFlowchartWithStartPropertyWorkflow`: Confirms precedence of `Flowchart.Start` property over the `Start` activity.
  - `StartInSequenceWorkflow`: Demonstrates successful `Start` activity usage in a sequence.

- Added integration tests (`StartTests`) ensuring expected execution flows and `Start` activity behavior for each workflow.
- Added unit tests validating `Start` activity implementation and compliance with `IStartNode`.
- Ensures test coverage for `Start` activity behavior across flowchart, sequence, and property overrides.
2025-11-27 09:24:33 +01:00
Sipke Schoorstra 8700036123
Add unit and integration tests for Complete activity to validate composite workflows execution (#7108)
* Add unit and integration tests for `Complete` activity to validate composite workflows execution

- Introduced integration and unit tests covering `Complete` activity behavior in nested and simple composite workflows.
- Added `CompleteTests` for edge cases such as immediate parent completion and composite termination.
- Developed new composite activities (`InnerComposite`, `OuterComposite`, `SimpleComposite`) for testing scenarios.

* Remove unnecessary `Complete` constructors tests.
2025-11-26 12:26:31 +01:00