Skip to content

Add unit/regression tests#17

Merged
minisbett merged 42 commits into
masterfrom
unit-testing
May 6, 2026
Merged

Add unit/regression tests#17
minisbett merged 42 commits into
masterfrom
unit-testing

Conversation

@minisbett

@minisbett minisbett commented Mar 28, 2026

Copy link
Copy Markdown
Owner

Adds unit tests covering all of osu-native.

The unit test interacts with osu-native by calling the high-level [OsuNativeFunction] methods, rather than using the FFI. This is deemed okay, as the concept of FFI should always reliably work, and the error-handling that differentiates the higher-level functions from the native ones is deterministic and tested as well.

Coverage:

  • RulesetTests
  • BeatmapTests
  • ModTests
  • ModsCollectionTests
  • OsuDifficultyCalculatorTests
  • TaikoDifficultyCalculatorTests
  • CatchDifficultyCalculatorTests
  • ManiaDifficultyCalculatorTests
  • OsuPerformanceCalculatorTests
  • TaikoPerformanceCalculatorTests
  • CatchPerformanceCalculatorTests
  • ManiaPerformanceCalculatorTests
  • ErrorHandlerTests
  • ManagedObjectStoreTests (including handles)

Additionally, the following is done:

  • A .idea folder is added
  • The OsuNativeMarker is removed
  • osu.Native.OsuNative is introduced, and the entry assembly setting is moved there
  • The Test project is removed
  • some attribute structs are now explicitly declared as read-only

@minisbett minisbett self-assigned this Mar 28, 2026
@minisbett minisbett added feature A new functionality. area:code-quality The quality of the code. labels Mar 28, 2026
@minisbett minisbett marked this pull request as draft March 29, 2026 00:41
@minisbett minisbett marked this pull request as ready for review May 6, 2026 16:47
@minisbett minisbett merged commit 8a53f76 into master May 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:code-quality The quality of the code. feature A new functionality.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant