Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
public class HasValidOpeningClosingBrackets
[InlineData("hi", true)]
[InlineData("{}", true)]
[InlineData("[}", false)]
[InlineData("{hi(george)}", true)]
[InlineData("{hi(george]}", false)]
[InlineData("[{hi(george]})", false)]
[InlineData("([{[}}])", false)]
public void ReturnsExpectedOutputForStringWithBrackets(string input, bool expected)
// Arrange | Act
var result = Analyzer.HasValidOpeningClosingBrackets(input);
// Assert
Equal(expected, result);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment