private void GetPlayerStatsCallback1(GetPlayerStatisticsResult result) { var testContext = (UUnitTestContext)result.CustomData; _testInteger = 0; foreach (var eachStat in result.Statistics) { if (eachStat.StatisticName == TEST_STAT_NAME) { _testInteger = eachStat.Value; } } _testInteger = (_testInteger + 1) % 100; // This test is about the Expected value changing - but not testing more complicated issues like bounds var updateRequest = new UpdatePlayerStatisticsRequest { Statistics = new List <StatisticUpdate> { new StatisticUpdate { StatisticName = TEST_STAT_NAME, Value = _testInteger } } }; clientInstance.UpdatePlayerStatistics(updateRequest, PlayFabUUnitUtils.ApiActionWrapper <UpdatePlayerStatisticsResult>(testContext, UpdatePlayerStatsCallback), PlayFabUUnitUtils.ApiActionWrapper <PlayFabError>(testContext, SharedErrorCallback), testContext); }