Skip to content

Update to mstest 4.0.0 and fix bug in config iterator.#586

Merged
teo-tsirpanis merged 4 commits into
TileDB-Inc:mainfrom
teo-tsirpanis:mstest
Oct 15, 2025
Merged

Update to mstest 4.0.0 and fix bug in config iterator.#586
teo-tsirpanis merged 4 commits into
TileDB-Inc:mainfrom
teo-tsirpanis:mstest

Conversation

@teo-tsirpanis

Copy link
Copy Markdown
Member

Manual application of #585, after fixing breaking changes.

@gemini-code-assist

Copy link
Copy Markdown

Summary of Changes

Hello @teo-tsirpanis, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request primarily focuses on upgrading the project's testing infrastructure by updating the MSTest framework to its latest major version, 4.0.0. This update necessitated a series of targeted changes across the test files to adapt to breaking changes and incorporate new, more robust assertion methods. The goal is to ensure the test suite remains current, reliable, and adheres to modern C# and testing best practices.

Highlights

  • MSTest Framework Upgrade: The MSTest testing framework has been updated to version 4.0.0, requiring several adjustments across the test suite to maintain compatibility and leverage new features.
  • Assertion Method Updates: Many Assert.ThrowsException calls have been replaced with Assert.ThrowsExactly for more precise exception type checking. Additionally, Assert.AreEqual(true, ...) and Assert.AreEqual(false, ...) have been updated to Assert.IsTrue(...) and Assert.IsFalse(...) respectively. Assertions checking collection counts now use Assert.HasCount or Assert.IsEmpty.
  • Test Method Refactoring: Several private helper methods in test classes have been made static where appropriate, and [DataTestMethod] attributes have been changed to [TestMethod] to align with MSTest v4 changes.
  • Code Modernization: Timestamp calculations now use DateTime.UnixEpoch for improved clarity and efficiency. A GetHashCode implementation was added to the Entry record struct in IncompleteQueryTest.cs for better record struct behavior.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request successfully updates MSTest to version 4.0.0 and applies the necessary code changes. The changes are well-executed, including updating test attributes and adopting new, more expressive assertions like ThrowsExactly, HasCount, and IsGreaterThanOrEqualTo. The refactorings, such as making test helpers static, using DateTime.UnixEpoch, and improving the ConfigIterator test, enhance code quality and maintainability. The correctness fix for GetHashCode in IncompleteQueryTest.cs is particularly valuable. I have a couple of suggestions to further improve the code by removing now-unused parameters.

@teo-tsirpanis teo-tsirpanis changed the title Update to mstest 4.0.0. Update to mstest 4.0.0 and fix bug in config iterator. Oct 15, 2025
public bool MoveNext()
{
if (!_iterator.Done())
if (_iterator.Done())

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This typo was after I updated the config iterator tests; I will make a patch release after merging this PR.

@teo-tsirpanis
teo-tsirpanis merged commit 4828b84 into TileDB-Inc:main Oct 15, 2025
4 checks passed
@teo-tsirpanis
teo-tsirpanis deleted the mstest branch October 15, 2025 21:11
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