1414namespace Mojang . Api . Skins . Test ;
1515public class SkinsClientTests
1616{
17- private ProfileProperties _profileProperties = new ProfileProperties
17+ private readonly ProfileProperties _profileProperties = new ( )
1818 {
1919 Name = "FakePlayer" ,
2020 Id = Guid . NewGuid ( ) ,
21- Properties = new ProfileProperty [ ] {
21+ Properties = [
2222 new ProfileProperty ( ) {
2323 Name = "textures" ,
2424 Value = "ewogICJ0aW1lc3RhbXAiIDogMTcwNTI0MDM4NTE1MSwKICAicHJvZmlsZUlkIiA6ICJlZGM2MzE5YjQ5NjM0ZDhmYmZkNTI1N2QxNzg5N2I0NSIsCiAgInByb2ZpbGVOYW1lIiA6ICJDd2lzdFNpbHYzciIsCiAgInRleHR1cmVzIiA6IHsKICAgICJTS0lOIiA6IHsKICAgICAgInVybCIgOiAiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS83ZTNjNWQ1MTM4MTE1YTRmNjBjYTRmMGMwMTEyZjk3NmFmYmJjZjk3MGNmY2Y5ZWM1NDk0NDMyNTQ1Njg0NWIxIgogICAgfSwKICAgICJDQVBFIiA6IHsKICAgICAgInVybCIgOiAiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8yMzQwYzBlMDNkZDI0YTExYjE1YThiMzNjMmE3ZTllMzJhYmIyMDUxYjI0ODFkMGJhN2RlZmQ2MzVjYTdhOTMzIgogICAgfQogIH0KfQ=="
2525 }
26- }
26+ ]
2727 } ;
28- private SkinData _defaultSkinData = new SkinData { SkinType = SkinType . Slim , TextureBytes = new byte [ ] { 1 , 2 , 3 , 4 , 5 , 6 } , TextureSize = new Size ( 64 , 64 ) } ;
29- private CapeData _defaultCapeData = new CapeData { CapeName = "TestCape" , TextureBytes = new byte [ ] { 1 , 2 , 3 } , TextureSize = new Size ( 64 , 32 ) } ;
28+ private readonly SkinData _defaultSkinData = new ( ) { SkinType = SkinType . Slim , TextureBytes = [ 1 , 2 , 3 , 4 , 5 , 6 ] , TextureSize = new Size ( 64 , 64 ) } ;
29+ private readonly CapeData _defaultCapeData = new ( ) { CapeName = "TestCape" , TextureBytes = [ 1 , 2 , 3 ] , TextureSize = new Size ( 64 , 32 ) } ;
3030
3131
3232 private readonly Mock < IProfileInformationRepository > _profileInformationRepositoryMock ;
@@ -47,7 +47,7 @@ public SkinsClientTests()
4747 _textureCropperMock = new Mock < ITextureCropper > ( ) ;
4848 _modernSkinConverterMock = new Mock < IModernSkinConverter > ( ) ;
4949 _skinTypeIdentifierMock = new Mock < ISkinTypeIdentifier > ( ) ;
50- }
50+ }
5151
5252 [ Fact ]
5353 public async Task GetAsync_ByName_ReturnsValidPlayerData ( )
@@ -140,5 +140,5 @@ public void GetFromFile_WithCape_ReturnsValidPlayerData()
140140 _profileTexturesRepositoryMock . Verify ( repo => repo . GetCapeLocal ( _defaultCapeData . TextureBytes ) , Times . Once ( ) ) ;
141141 }
142142
143- private SkinsClient CreateClient ( ) => new SkinsClient ( _profileInformationRepositoryMock . Object , _profilePropertiesRepositoryMock . Object , _profileTexturesRepositoryMock . Object , _capeTextureIdentifierMock . Object , _imageUtilitiesMock . Object , _textureCropperMock . Object , _modernSkinConverterMock . Object , _skinTypeIdentifierMock . Object ) ;
143+ private SkinsClient CreateClient ( ) => new ( _profileInformationRepositoryMock . Object , _profilePropertiesRepositoryMock . Object , _profileTexturesRepositoryMock . Object , _capeTextureIdentifierMock . Object , _imageUtilitiesMock . Object , _textureCropperMock . Object , _modernSkinConverterMock . Object , _skinTypeIdentifierMock . Object ) ;
144144}
0 commit comments