Version 3.0.261

This commit is contained in:
ohauff 2021-11-14 23:27:29 +01:00
parent 8aa3089f32
commit 4bccfe740b
80 changed files with 2672 additions and 458 deletions

View file

@ -1,6 +1,8 @@
using Newtonsoft.Json;
using NUnit.Framework;
using System;
using TestFramework;
using TestShareeLib;
using TINK.Model.State;

View file

@ -12,6 +12,7 @@ using TINK.Model.User.Account;
using Plugin.Permissions.Abstractions;
using TestShareeLib.Repository;
using TestFramework.Repository;
namespace TestTINKLib.Fixtures.UseCases.Logout
{
@ -56,7 +57,7 @@ namespace TestTINKLib.Fixtures.UseCases.Logout
Assert.IsTrue(l_oTinkApp.ActiveUser.IsLoggedIn);
// There are 6 bikes available and 2, one reserved and one rented by javaminsiter.
Assert.AreEqual(
8,
10,
l_oTinkApp.GetConnector(true).Query.GetBikesAsync().Result.Response.Count,
"Sum of bikes is 6 occupied plus 2 occupied.");
Assert.AreEqual(2,
@ -70,7 +71,7 @@ namespace TestTINKLib.Fixtures.UseCases.Logout
Assert.IsFalse(l_oTinkApp.ActiveUser.IsLoggedIn);
Assert.AreEqual(
6,
8,
l_oTinkApp.GetConnector(true).Query.GetBikesAsync().Result.Response.Count,
"Sum of bikes is 6 occupied, no one occupied because no user is logged in");
Assert.AreEqual(

View file

@ -2,9 +2,7 @@
using System;
using TINK.Model;
using TINK.Model.Connector;
using TINK.Repository;
using TINK.Model.Services.CopriApi.ServerUris;
using static TINK.Repository.CopriCallsMemory;
using TINK.Services;
using NSubstitute;
using TINK.Model.Services.Geolocation;
@ -13,9 +11,9 @@ using TINK.Model.Device;
using TINK.Model.User.Account;
using Plugin.Permissions.Abstractions;
using System.Threading.Tasks;
using TestShareeLib.Repository;
using TestFramework.Repository;
namespace TestTINKLib.Fixtures.UseCases.Login
namespace TestShareeLib.UseCases.Login
{
[TestFixture]
public class TestTinkApp
@ -51,7 +49,7 @@ namespace TestTINKLib.Fixtures.UseCases.Login
Assert.IsFalse(l_oTinkApp.ActiveUser.IsLoggedIn);
Assert.AreEqual(
6,
8,
l_oTinkApp.GetConnector(true).Query.GetBikesAsync().Result.Response.Count,
"Sum of bikes is 6 occupied, no one occupied because no user is logged in");
Assert.AreEqual(
@ -66,7 +64,7 @@ namespace TestTINKLib.Fixtures.UseCases.Login
Assert.IsTrue(l_oTinkApp.ActiveUser.IsLoggedIn);
Assert.AreEqual(
8,
10,
l_oTinkApp.GetConnector(true).Query.GetBikesAsync().Result.Response.Count,
"Sum of bikes is 6 occupied plus 2 occupied.");
Assert.AreEqual(

View file

@ -1,18 +0,0 @@
namespace TestTINKLib
{
/// <summary>
/// Provides helper functionality. Used in TestShareeLib and TestTINKLib.
/// </summary>
public static class TestHelper
{
/// <summary>
/// Eases comparison of xml- files.
/// </summary>
/// <param name="p_strXmlFile"></param>
/// <returns></returns>
public static string PrepareXmlForStringCompare(string p_strXmlFile)
{
return p_strXmlFile.Replace("\r\n", string.Empty).Replace("\t", string.Empty).Replace(" ", string.Empty);
}
}
}

View file

@ -34,6 +34,7 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\TestFramework\TestFramework.csproj" />
<ProjectReference Include="..\TINKLib\TINKLib.csproj" />
</ItemGroup>

View file

@ -7,6 +7,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TestShareeLib", "TestSharee
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TINKLib", "..\TINKLib\TINKLib.csproj", "{F3C0288B-7527-42B0-AA43-CC461766D6E1}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TestFramework", "..\TestFramework\TestFramework.csproj", "{F86692DF-BCB9-4236-8337-04CB65EE4256}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -21,6 +23,10 @@ Global
{F3C0288B-7527-42B0-AA43-CC461766D6E1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F3C0288B-7527-42B0-AA43-CC461766D6E1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F3C0288B-7527-42B0-AA43-CC461766D6E1}.Release|Any CPU.Build.0 = Release|Any CPU
{F86692DF-BCB9-4236-8337-04CB65EE4256}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F86692DF-BCB9-4236-8337-04CB65EE4256}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F86692DF-BCB9-4236-8337-04CB65EE4256}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F86692DF-BCB9-4236-8337-04CB65EE4256}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE