コード例 #1
0
 public Dataset(SsisTestSuite ssisTestSuite, string name, ConnectionRef connectionReference, bool isResultsStored, string query, DataTable results)
     : this(ssisTestSuite, name, connectionReference, isResultsStored, query)
 {
     Results = results;
 }
コード例 #2
0
 public ParameterCommand(SsisTestSuite testSuite, object parent, XmlNode commandXml)
     : base(testSuite, parent, commandXml)
 {
     InitializeProperties();
 }
コード例 #3
0
 public PropertyCommand(SsisTestSuite testSuite, object parent, XmlNode commandXml)
     : base(testSuite, parent, commandXml)
 {
     InitializeProperties(PropertyOperation.Get.ToString(), string.Empty, string.Empty);
 }
コード例 #4
0
 public TestRef(SsisTestSuite testSuite, string path)
 {
     TestSuite = testSuite;
     Path      = path;
 }
コード例 #5
0
 public ParameterCommand(SsisTestSuite testSuite, object parent)
     : base(testSuite, parent)
 {
     InitializeProperties();
 }
コード例 #6
0
 internal Context(SsisTestSuite testSuite)
     : this()
 {
     TestSuite = testSuite;
 }
コード例 #7
0
        public TestRef(SsisTestSuite testSuite, XmlNode testRef)
        {
            TestSuite = testSuite;

            LoadFromXml(testRef);
        }
コード例 #8
0
 public Test(SsisTestSuite testSuite, string name, string project, string package, string password, string task)
     : this(testSuite, name, project, package, password, task, DTSExecResult.Success)
 {
 }
コード例 #9
0
 public Test(SsisTestSuite testSuite, string name, string package, string password, string task, DTSExecResult taskResult)
     : this(testSuite, name, null, package, password, task, taskResult)
 {
 }
コード例 #10
0
 protected CommandBase(SsisTestSuite testSuite, object parent, XmlNode commandXml)
     : this(testSuite, commandXml)
 {
     Parent = parent;
 }
コード例 #11
0
 // TODO: Add Context to all parents, children
 internal Test(Context context, SsisTestSuite testSuite, string name, string package, string password, string task)
     : this(testSuite, name, null, package, password, task, DTSExecResult.Success)
 {
     _context = context;
 }
コード例 #12
0
 protected CommandBase(SsisTestSuite testSuite, XmlNode commandXml)
     : this(testSuite)
 {
     LoadFromXml(commandXml);
 }
コード例 #13
0
 protected CommandBase(SsisTestSuite testSuite, object parent)
     : this(testSuite)
 {
     Parent = parent;
 }
コード例 #14
0
 protected CommandBase(SsisTestSuite testSuite)
     : this()
 {
     _testSuite = testSuite;
 }
コード例 #15
0
 public ProcessCommand(SsisTestSuite testSuite, object parent, string commandXml)
     : base(testSuite, parent, commandXml)
 {
     InitializeProperties();
 }
コード例 #16
0
 public VariableCommand(SsisTestSuite testSuite)
     : base(testSuite)
 {
     InitializeProperties();
 }
コード例 #17
0
 public ProcessCommand(SsisTestSuite testSuite, XmlNode commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties();
 }
コード例 #18
0
 public VariableCommand(SsisTestSuite testSuite, string commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties();
 }
コード例 #19
0
 internal Context(SsisTestSuite testSuite, Test test)
     : this(testSuite)
 {
     Test = test;
 }
コード例 #20
0
 public DataCompareCommand(SsisTestSuite testSuite)
     : base(testSuite)
 {
     InitializeProperties();
 }
コード例 #21
0
        public void Execute()
        {
            SsisTestSuite ts = new SsisTestSuite(this.Path);

            TestSuite.RunTestSuite(ts);
        }
コード例 #22
0
 public DataCompareCommand(SsisTestSuite testSuite, object parent)
     : base(testSuite, parent)
 {
     InitializeProperties();
 }
コード例 #23
0
 public ParameterCommand(SsisTestSuite testSuite)
     : base(testSuite)
 {
     InitializeProperties();
 }
コード例 #24
0
 public DataCompareCommand(SsisTestSuite testSuite, string commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties();
 }
コード例 #25
0
 public ParameterCommand(SsisTestSuite testSuite, string commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties();
 }
コード例 #26
0
ファイル: Helper.cs プロジェクト: steveculshaw/ssisUnit
        public static Package LoadPackage(SsisTestSuite testSuite, string packageName, SecureString packagePassword, string projectPath, out object loadedProject)
        {
            var        ssisApp    = new Application();
            Package    package    = null;
            PackageRef packageRef = null;

            loadedProject = null;

            bool isPackagePathFilePath = false;

            if (string.IsNullOrEmpty(projectPath) && packageName.Contains(".dtsx"))
            {
                // Assume that it is a file path.
                var fileInfo = new FileInfo(Environment.ExpandEnvironmentVariables(packageName));

                if (fileInfo.Exists)
                {
                    isPackagePathFilePath = true;

                    if (packagePassword != null)
                    {
                        ssisApp.PackagePassword = ConvertToUnsecureString(packagePassword);
                    }

                    try
                    {
                        package = ssisApp.LoadPackage(fileInfo.FullName, null);
                    }
                    catch (DtsRuntimeException)
                    {
                        isPackagePathFilePath = false;
                    }
                }
            }

            if (!isPackagePathFilePath)
            {
                if (testSuite.PackageList.ContainsKey(packageName))
                {
                    packageRef = testSuite.PackageList[packageName];
                }
                else
                {
                    foreach (PackageRef packageReference in testSuite.PackageList.Values)
                    {
                        if ((packageReference.Name != null &&
                             string.Compare(
                                 packageReference.Name,
                                 packageName,
                                 StringComparison.OrdinalIgnoreCase) == 0) ||
                            (packageReference.PackagePath != null &&
                             string.Compare(
                                 packageReference.PackagePath,
                                 packageName,
                                 StringComparison.OrdinalIgnoreCase) == 0))
                        {
                            packageRef = packageReference;

                            break;
                        }
                    }
                }

                if (packageRef == null)
                {
                    throw new KeyNotFoundException(string.Format(CultureInfo.CurrentCulture, "{0} was not found in the test suite package references.", packageName));
                }

                package = packageRef.LoadPackage();

#if SQL2012 || SQL2014 || SQL2017
                loadedProject = packageRef.Project;
#endif
            }

            return(package);
        }
コード例 #27
0
 public PropertyCommand(SsisTestSuite testSuite)
     : base(testSuite)
 {
     InitializeProperties(PropertyOperation.Get.ToString(), string.Empty, string.Empty);
 }
コード例 #28
0
 public ProcessCommand(SsisTestSuite testSuite)
     : base(testSuite)
 {
     InitializeProperties();
 }
コード例 #29
0
 public ComponentSourceCommand(SsisTestSuite testSuite, string commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties(PropertyOperation.Get.ToString(), string.Empty, string.Empty);
 }
コード例 #30
0
 public DirectoryCommand(SsisTestSuite testSuite, XmlNode commandXml)
     : base(testSuite, commandXml)
 {
     InitializeProperties();
 }