Esempio n. 1
0
        // if the version asked for is present, return status code 0
        // otherwise return status code -1
        static int Main(string[] args)
        {
            if (args.Length == 0)
            {
                return(-1);
            }

            try
            {
                return(Detective.InstallationExists(args[0]) ? 0 : -1);
            }
            catch
            {
                // suppress all errors!
            }

            return(-1);
        }
Esempio n. 2
0
 public void CheckForInstallation_CanFindRevit2013()
 {
     // must install revit 2013
     Assert.True(Detective.InstallationExists("Revit2013"));
 }
Esempio n. 3
0
 public void CheckForInstallation_CantFindVasariBeta2()
 {
     // non-existent version
     Assert.False(Detective.InstallationExists("VasariBeta2"));
 }
Esempio n. 4
0
 public void CheckForInstallation_CantFindRevit2012()
 {
     // cannot have revit 2012 installed
     Assert.False(Detective.InstallationExists("Revit2012"));
 }
Esempio n. 5
0
 public void CheckForInstallation_CanFindVasariBeta3()
 {
     // only works on a machine with vasari beta 3!
     Assert.True(Detective.InstallationExists("VasariBeta3"));
 }