def METHOD_NAME():
    """
    Test to uncomment specified commented lines in a file
    """
    with patch.object(os.path, "exists", MagicMock(return_value=True)):
        name = "/etc/aliases" if salt.utils.platform.is_darwin() else "/etc/fstab"
        regex = "bind 127.0.0.1"
        ret = {"name": name, "result": False, "comment": "", "changes": {}}
        comt = "Must provide name to file.uncomment"
        ret.update({"comment": comt, "name": ""})
        assert filestate.uncomment("", regex) == ret
        mock_t = MagicMock(return_value=True)
        mock_f = MagicMock(return_value=False)
        mock = MagicMock(side_effect=[False, True, False, False, True, True, True])
        with patch.object(os.path, "isabs", mock_f):
            comt = "Specified file {} is not an absolute path".format(name)
            ret.update({"comment": comt, "name": name})
            assert filestate.uncomment(name, regex) == ret
        with patch.object(os.path, "isabs", mock_t):
            with patch.dict(
                filestate.__salt__,
                {
                    "file.search": mock,
                    "file.uncomment": mock_t,
                    "file.comment_line": mock_t,
                },
            ):
                comt = "Pattern already uncommented"
                ret.update({"comment": comt, "result": True})
                assert filestate.uncomment(name, regex) == ret
                comt = "{}: Pattern not found".format(regex)
                ret.update({"comment": comt, "result": False})
                assert filestate.uncomment(name, regex) == ret
                with patch.dict(filestate.__opts__, {"test": True}):
                    comt = "File {} is set to be updated".format(name)
                    ret.update(
                        {"comment": comt, "result": None, "changes": {name: "updated"}}
                    )
                    assert filestate.uncomment(name, regex) == ret
                with patch.dict(filestate.__opts__, {"test": False}):
                    with patch.object(
                        salt.utils.files, "fopen", MagicMock(mock_open())
                    ):
                        comt = "Uncommented lines successfully"
                        ret.update({"comment": comt, "result": True, "changes": {}})
                        assert filestate.uncomment(name, regex) == ret