public void GetTokenTypeFromQuickInfoWithIncorrectObjectNameTest() { Scripter peekDefinition = new Scripter(null, null); string objectName = "test"; string quickInfoText = "table master.dbo.tableName"; string result = peekDefinition.GetTokenTypeFromQuickInfo(quickInfoText, objectName, StringComparison.Ordinal); string expected = null; Assert.Equal(expected, result); }
public void GetTokenTypeFromQuickInfoWithValidStringsandIgnoreCaseTest() { Scripter peekDefinition = new Scripter(null, null); string objectName = "tablename"; string quickInfoText = "table master.dbo.tableName"; string result = peekDefinition.GetTokenTypeFromQuickInfo(quickInfoText, objectName, StringComparison.OrdinalIgnoreCase); string expected = "table"; Assert.Equal(expected, result); }