コード例 #1
0
        public void dxT866644nonxaf()
        {
            //arrang
            var confFile  = Resources.dxT866644_nonxaf__config;
            var xDocument = XDocument.Parse(confFile);
            var provider  = new SolutionDataProvider();
            //act
            var res = provider.GetDBName(xDocument);

            //assert
            Assert.AreEqual("28-6-dxT866644", res);
        }
コード例 #2
0
        public void xafConfig2()
        {
            //arrang
            var confFile  = Resources.AppTrueXAF;
            var xDocument = XDocument.Parse(confFile);
            var provider  = new SolutionDataProvider();

            //act
            var res = provider.GetDBName(xDocument);

            //assert
            Assert.AreEqual("28-22-dxT866654v1", res);
        }
コード例 #3
0
        /// <summary>
        /// This function is the callback used to execute the command when the menu item is clicked.
        /// See the constructor to see how the menu item is associated with this function using
        /// OleMenuCommandService service and MenuCommand class.
        /// </summary>
        /// <param name="sender">Event sender.</param>
        /// <param name="e">Event args.</param>
        private void Execute(object sender, EventArgs e)
        {
            var solutionData = new SolutionDataProvider();

            solutionData.GetDataFromSolution(solutionFullName);
            if (solutionData.DatabaseName != null)
            {
                backupDB(solutionData.DatabaseName, solutionData.SoluitonParentFolderName);
            }
            else
            {
                VsShellUtilities.ShowMessageBox(this.package,
                                                "No database was found",
                                                "Not found",
                                                OLEMSGICON.OLEMSGICON_INFO,
                                                OLEMSGBUTTON.OLEMSGBUTTON_OK,
                                                OLEMSGDEFBUTTON.OLEMSGDEFBUTTON_FIRST);
            }
        }