public void TestConstructorSetsPropertiesCorrectly()
        {
            XboxApplicationDefinition applicationDefinition = new XboxApplicationDefinition(Aumid);

            Assert.AreEqual(ApplicationId, applicationDefinition.ApplicationId, "The ApplicationId property was not set correctly.");
            Assert.AreEqual(PackageFamilyName, applicationDefinition.PackageFamilyName, "The PackageFamilyName property was not set correctly.");
            Assert.AreEqual(Aumid, applicationDefinition.Aumid, "The Aumids property was not set correctly.");
        }
        /// <summary>
        /// Launches the given application.
        /// </summary>
        /// <param name="systemIpAddress">The "System Ip" address of the Xbox kit.</param>
        /// <param name="application">The application to be launched.</param>
        /// <exception cref="System.ArgumentNullException">Thrown if the <paramref name="package"/> parameter is null.</exception>
        protected override void LaunchApplicationImpl(string systemIpAddress, XboxApplicationDefinition application)
        {
            if (application == null)
            {
                throw new ArgumentNullException("application");
            }

            this.XboxXdk.LaunchApplication(systemIpAddress, application.Aumid);
        }
        /// <summary>
        /// Launches the given application with command line arguments.
        /// </summary>
        /// <param name="systemIpAddress">The "System Ip" address of the Xbox kit.</param>
        /// <param name="application">The application to be launched.</param>
        /// <param name="arguments">Command line arguments to pass to the package executable.</param>
        /// <exception cref="System.ArgumentNullException">Thrown if the <paramref name="package"/> parameter is null.</exception>
        protected override void LaunchApplicationImpl(string systemIpAddress, XboxApplicationDefinition application, string arguments)
        {
            if (application == null)
            {
                throw new ArgumentNullException("application");
            }

            if (string.IsNullOrEmpty(arguments))
            {
                // Passing null or empty string reverts to regular LaunchApplication behavior
                this.XboxXdk.LaunchApplication(systemIpAddress, application.Aumid);
            }
            else
            {
                // Passing valid arguments concatenates them to AUMID with a space separator (we trust native Xtf to handle this properly)
                this.XboxXdk.LaunchApplication(systemIpAddress, string.Format(CultureInfo.InvariantCulture, "{0} {1}", application.Aumid, arguments));
            }
        }
 public void TestConstructorThrowsWithImproperlyFormattedAumid()
 {
     XboxApplicationDefinition package = new XboxApplicationDefinition("WrongFormat");
 }
 public void TestConstructorThrowsWithEmptyAumid()
 {
     XboxApplicationDefinition package = new XboxApplicationDefinition(string.Empty);
 }