Skip to content

Add tests#10

Closed
BlueXTX wants to merge 23 commits intosp-tarkov:Refactorfrom
BlueXTX:pr/bluextx/9
Closed

Add tests#10
BlueXTX wants to merge 23 commits intosp-tarkov:Refactorfrom
BlueXTX:pr/bluextx/9

Conversation

@BlueXTX
Copy link

@BlueXTX BlueXTX commented Jan 13, 2025

No description provided.

The changes include:
- Moved static weapon IDs and forced items from LootDumpProcessorContext to ForcedStatic record
- Added ForcedStatic configuration injection in StaticLootProcessor and StaticContainerProcessor
- Improved immutability by using read-only collections in ForcedStatic model
- Simplified LootDumpProcessorContext by removing unused methods
The changes introduce a new `IForcedItemsProvider` abstraction to handle loading and caching of forced static and loose loot configurations. This improves the code by:

1. Making configuration loading asynchronous
2. Implementing caching of loaded configurations
3. Centralizing forced items configuration access
4. Removing direct file system dependencies from processors
5. Improving testability through dependency injection

The change also updates related processors and interfaces to use async/await pattern consistently.
# Conflicts:
#	source/LootDumpProcessor/Process/Processor/DumpProcessor/MultithreadSteppedDumpProcessor.cs
#	source/LootDumpProcessor/Process/QueuePipeline.cs
The commit:
- Removes mapId parameter from AmmoProcessor interface and implementation as it was unused
- Adds comprehensive BDD tests using Reqnroll (SpecFlow) for AmmoProcessor
- Adds table helper classes for BDD test data handling
- Configures Reqnroll in test project
- Updates existing unit tests to match new interface
@BlueXTX
Copy link
Author

BlueXTX commented Jan 13, 2025

Merge only after #8

@refringe refringe deleted the branch sp-tarkov:Refactor June 17, 2025 17:40
@refringe refringe closed this Jun 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants