Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Mono.Android-Tests] Remove obsolete .shproj file. #9758

Merged
merged 4 commits into from
Feb 12, 2025

Conversation

jpobst
Copy link
Contributor

@jpobst jpobst commented Feb 5, 2025

Mono.Android-Tests still uses a .shproj file from the time when we had both a Classic XA and .NET version. However, VS does not seem to support this anymore, and none of the included files appear in the IDE, making it hard to write new tests.

Remove the .shproj file and update the .csproj file to directly point to needed files.

Also do some other cleanups like removing tests that are no longer run and fixing directory structure.

Verified that both the main version and this PR run 885 tests on CI.

@jpobst jpobst force-pushed the dev/jpobst/mono-android-tests branch 4 times, most recently from 4302875 to 9c80d50 Compare February 6, 2025 21:13
@jpobst jpobst changed the title [Mono-Android-Tests] Remove obsolete .shproj file. [Mono.Android-Tests] Remove obsolete .shproj file. Feb 6, 2025
@jpobst jpobst force-pushed the dev/jpobst/mono-android-tests branch 2 times, most recently from d9a90d6 to 817e1bc Compare February 10, 2025 19:40
@jpobst jpobst marked this pull request as ready for review February 10, 2025 23:39
Copy link
Member

@jonathanpeppers jonathanpeppers left a comment

Choose a reason for hiding this comment

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

Did I misread the diff, or did a couple tests get deleted on accident?

Comment on lines -9 to -16
[TestFixture]
public class HandlerTest {

[Test]
public void RemoveDisposedInstance ()
{
using (var t = new HandlerThread ("RemoveDisposedInstance")) {
t.Start ();
Copy link
Member

Choose a reason for hiding this comment

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

I don't think we should delete this one?

Comment on lines -5 to -17
namespace Xamarin.Android.RuntimeTests
{
[TestFixture]
public class LocalizationTests
{
// https://bugzilla.xamarin.com/show_bug.cgi?id=31705
[Test]
public void EmbeddedResources_ShouldBeLocalized ()
{
CultureInfo culture = Thread.CurrentThread.CurrentCulture;
CultureInfo uiCulture = Thread.CurrentThread.CurrentUICulture;

Assert.AreEqual ("a", AppResources.String1, "Embedded string resource did not contain expected value.");
Copy link
Member

Choose a reason for hiding this comment

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

This test also looks good?

@jpobst
Copy link
Contributor Author

jpobst commented Feb 11, 2025

I removed tests that are not being run today in main, assuming they were obsolete and removed on purpose. I can try enabling them and see if they pass or not.

@jonathanpeppers
Copy link
Member

The two above look like they should pass, but Mono.Data.Sqlite/SqliteTests.cs can be deleted.

@jpobst jpobst force-pushed the dev/jpobst/mono-android-tests branch 3 times, most recently from 3c993eb to 36cabc7 Compare February 11, 2025 23:01
@jpobst
Copy link
Contributor Author

jpobst commented Feb 12, 2025

The two above look like they should pass, but Mono.Data.Sqlite/SqliteTests.cs can be deleted.

👍 Tests enabled.

@jpobst jpobst force-pushed the dev/jpobst/mono-android-tests branch from 36cabc7 to 678d36d Compare February 12, 2025 18:38
@jpobst jpobst merged commit d376590 into main Feb 12, 2025
58 checks passed
@jpobst jpobst deleted the dev/jpobst/mono-android-tests branch February 12, 2025 22:34
grendello added a commit that referenced this pull request Feb 13, 2025
* main:
  [Mono.Android-Tests] Remove obsolete `.shproj` file. (#9758)
  [NativeAOT] introduce `Microsoft.Android.Runtime.NativeAOT.dll` (#9760)
jonathanpeppers pushed a commit that referenced this pull request Feb 13, 2025
Context: #9758

While enabling new tests for `Mono.Android-Tests`, git somehow ate
my files and made them all empty.  I fixed the ones that CI found but
didn't notice the other empty files.

Add the content of these files back.

Verified on CI run that the 2 new tests are indeed being run and succeed.
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.

3 participants