public TaskCompletionSource <string> SetVisitorIdentifier() { stringOutput = new TaskCompletionSource <string>(); ACPAnalytics.SetVisitorIdentifier("testVisitorIdentifier"); stringOutput.SetResult("completed"); return(stringOutput); }
public void GetCustomVisitorIdentifier_Gets_PreviouslySetCustomVisitorIdentifier() { // setup latch = new CountdownEvent(1); var expectedIdentifier = "someVisitorIdentifier"; ACPAnalytics.SetVisitorIdentifier(expectedIdentifier); // test ACPAnalytics.GetVisitorIdentifier(new VisitorIdentifierCallback()); latch.Wait(); latch.Dispose(); // verify Assert.That(retrievedVisitorIdentifier, Is.EqualTo(expectedIdentifier)); }
public void GetCustomVisitorIdentifier_Gets_PreviouslySetCustomVisitorIdentifier() { // setup var latch = new CountdownEvent(1); string retrievedIdentifier = ""; string expectedIdentifier = "someVisitorIdentifier"; ACPAnalytics.SetVisitorIdentifier(expectedIdentifier); // test ACPAnalytics.GetVisitorIdentifier(callback => { retrievedIdentifier = callback.ToString(); latch.Signal(); }); latch.Wait(); latch.Dispose(); // verify Assert.That(retrievedIdentifier, Is.EqualTo(expectedIdentifier)); }
partial void SetVisitorIdentifier(UIButton sender) { ACPAnalytics.SetVisitorIdentifier("testVisitorIdentifier"); Console.WriteLine("SetVisitorIdentifier: Completed"); }
void SetVisitorIdentifier() { Debug.Log("Calling setVisitorIdentifier"); ACPAnalytics.SetVisitorIdentifier(visitorIdentifier.text); }