protected override void SetUp()
 {
     if (!TITLE_INFO_SET)
     {
         UUnitAssert.Skip(); // We cannot do client tests if the titleId is not given
     }
 }
        protected override void SetUp()
        {
            if (EXEC_ONCE)
            {
                string filename = "C:/depot/pf-main/tools/SDKBuildScripts/testTitleData.json"; // TODO: Figure out how to not hard code this
                if (File.Exists(filename))
                {
                    string testInputsFile = Util.ReadAllFileText(filename);

                    var testInputs = SimpleJson.DeserializeObject <Dictionary <string, string> >(testInputsFile, Util.ApiSerializerStrategy);
                    SetTitleInfo(testInputs);
                }
                else
                {
                    Console.WriteLine("Loading testSettings file failed: " + filename);
                    Console.WriteLine("From: " + Directory.GetCurrentDirectory());
                }
                EXEC_ONCE = false;
            }

            if (!TITLE_INFO_SET)
            {
                UUnitAssert.Skip(); // We cannot do client tests if the titleId is not given
            }
        }
Example #3
0
        protected override void SetUp()
        {
            if (EXEC_ONCE)
            {
                string filename = "C:/depot/pf-main/tools/SDKBuildScripts/testTitleData.json"; // TODO: Figure out how to not hard code this
                if (File.Exists(filename))
                {
                    string testInputsFile = File.ReadAllText(filename);
                    var    serializer     = JsonSerializer.Create(PlayFab.Internal.Util.JsonSettings);
                    var    testInputs     = serializer.Deserialize <Dictionary <string, string> >(new JsonTextReader(new StringReader(testInputsFile)));
                    SetTitleInfo(testInputs);
                }
                else
                {
                    Console.WriteLine("Loading testSettings file failed: " + filename);
                    Console.WriteLine("From: " + Directory.GetCurrentDirectory());
                }
                EXEC_ONCE = false;
            }

            if (!TITLE_INFO_SET)
            {
                UUnitAssert.Skip(); // We cannot do client tests if the titleId is not given
            }
        }