#define BOOST_TEST_MODULE SolutionTest

#include "solution.hpp"

#define BOOST_TEST_DYN_LINK
#include <boost/test/unit_test.hpp>

BOOST_AUTO_TEST_SUITE(SolutionSuite)

BOOST_AUTO_TEST_CASE(PlainTest1)
{
    string s = "aa";
    string p = "a";
    bool results = Solution().isMatch(s, p);

    bool expected = false;
    BOOST_CHECK_EQUAL(results, expected);
}

BOOST_AUTO_TEST_CASE(PlainTest2)
{
    string s = "aa";
    string p = "a*";
    bool results = Solution().isMatch(s, p);

    bool expected = true;
    BOOST_CHECK_EQUAL(results, expected);
}

BOOST_AUTO_TEST_CASE(PlainTest3)
{
    string s = "ab";
    string p = ".*";
    bool results = Solution().isMatch(s, p);

    bool expected = true;
    BOOST_CHECK_EQUAL(results, expected);
}

BOOST_AUTO_TEST_CASE(PlainTest4)
{
    string s = "aab";
    string p = "c*a*b";
    bool results = Solution().isMatch(s, p);

    bool expected = true;
    BOOST_CHECK_EQUAL(results, expected);
}

BOOST_AUTO_TEST_CASE(PlainTest5)
{
    string s = "mississippi";
    string p = "mis*is*p*.";
    bool results = Solution().isMatch(s, p);

    bool expected = false;
    BOOST_CHECK_EQUAL(results, expected);
}

BOOST_AUTO_TEST_SUITE_END()