Пример #1
0
        [InlineData("schema.table", null, new [] { "schema", "table" })]                  // Split object name into schema
        public void ShouldUseSchemaNameIfDefined(string objName, string schemaName, string[] expectedNameParts)
        {
            // Setup: Create an edit data service without a session
            var eds = new EditDataService(null, null, null);

            // If:
            // ... I have init params with an object and schema parameter
            var initParams = new EditInitializeParams
            {
                ObjectName = objName,
                SchemaName = schemaName,
                OwnerUri   = Common.OwnerUri,
                ObjectType = "table"
            };

            // ... And I get named parts for that
            string[] nameParts = EditSession.GetEditTargetName(initParams);

            // Then:
            Assert.Equal(expectedNameParts, nameParts);
        }