test/charset-test
test/config-test
test/date-test
+test/envlist-test
test/group-test
test/idna-test
test/neomutt-test
test/date/mutt_date_parse_date.o \
test/date/mutt_date_parse_imap.o
+ENVLIST_OBJS = test/envlist/main.o \
+ test/envlist/mutt_envlist_free.o \
+ test/envlist/mutt_envlist_getlist.o \
+ test/envlist/mutt_envlist_init.o \
+ test/envlist/mutt_envlist_set.o \
+ test/envlist/mutt_envlist_unset.o
+
GROUP_OBJS = test/group/main.o \
test/group/mutt_grouplist_add_addrlist.o \
test/group/mutt_grouplist_add.o \
TEST_DATE = test/date-test$(EXEEXT)
+TEST_ENVLIST = test/envlist-test$(EXEEXT)
+
TEST_GROUP = test/group-test$(EXEEXT)
TEST_IDNA = test/idna-test$(EXEEXT)
TEST_STRING = test/string-test$(EXEEXT)
.PHONY: test
-test: $(TEST_BINARY) $(TEST_ADDRESS) $(TEST_BASE64) $(TEST_BUFFER) $(TEST_CHARSET) $(TEST_CONFIG) $(TEST_DATE) $(TEST_GROUP) $(TEST_IDNA) $(TEST_PATH) $(TEST_PATTERN) $(TEST_STRING)
+test: $(TEST_BINARY) $(TEST_ADDRESS) $(TEST_BASE64) $(TEST_BUFFER) $(TEST_CHARSET) $(TEST_CONFIG) $(TEST_DATE) $(TEST_ENVLIST) $(TEST_GROUP) $(TEST_IDNA) $(TEST_PATH) $(TEST_PATTERN) $(TEST_STRING)
$(TEST_BINARY)
$(TEST_ADDRESS)
$(TEST_BASE64)
$(TEST_BUFFER)
$(TEST_CONFIG)
$(TEST_DATE)
+ $(TEST_ENVLIST)
$(TEST_GROUP)
$(TEST_IDNA)
$(TEST_PATH)
$(TEST_DATE): $(PWD)/test/date $(DATE_OBJS) $(MUTTLIBS)
$(CC) -o $@ $(DATE_OBJS) $(MUTTLIBS) $(LDFLAGS) $(LIBS)
+$(TEST_ENVLIST): $(PWD)/test/envlist $(ENVLIST_OBJS) $(MUTTLIBS)
+ $(CC) -o $@ $(ENVLIST_OBJS) $(MUTTLIBS) $(LDFLAGS) $(LIBS)
+
$(TEST_GROUP): $(PWD)/test/group $(GROUP_OBJS) $(MUTTLIBS)
$(CC) -o $@ $(GROUP_OBJS) $(MUTTLIBS) $(LDFLAGS) $(LIBS)
$(PWD)/test/date:
$(MKDIR_P) $(PWD)/test/date
+$(PWD)/test/envlist:
+ $(MKDIR_P) $(PWD)/test/envlist
+
$(PWD)/test/group:
$(MKDIR_P) $(PWD)/test/group
$(PWD)/test/string:
$(MKDIR_P) $(PWD)/test/string
-all-test: $(TEST_BINARY) $(TEST_ADDRESS) $(TEST_BASE64) $(TEST_BUFFER) $(TEST_CHARSET) $(TEST_CONFIG) $(TEST_DATE) $(TEST_GROUP) $(TEST_IDNA) $(TEST_PATH) $(TEST_PATTERN) $(TEST_STRING)
+all-test: $(TEST_BINARY) $(TEST_ADDRESS) $(TEST_BASE64) $(TEST_BUFFER) $(TEST_CHARSET) $(TEST_CONFIG) $(TEST_DATE) $(TEST_ENVLIST) $(TEST_GROUP) $(TEST_IDNA) $(TEST_PATH) $(TEST_PATTERN) $(TEST_STRING)
clean-test:
$(RM) $(TEST_BINARY) $(TEST_OBJS) $(TEST_OBJS:.o=.Po) \
$(TEST_CHARSET) $(CHARSET_OBJS) $(CHARSET_OBJS:.o=.Po) \
$(TEST_CONFIG) $(CONFIG_OBJS) $(CONFIG_OBJS:.o=.Po) \
$(TEST_DATE) $(DATE_OBJS) $(DATE_OBJS:.o=.Po) \
+ $(TEST_ENVLIST) $(ENVLIST_OBJS) $(ENVLIST_OBJS:.o=.Po) \
$(TEST_GROUP) $(GROUP_OBJS) $(GROUP_OBJS:.o=.Po) \
$(TEST_IDNA) $(IDNA_OBJS) $(IDNA_OBJS:.o=.Po) \
$(TEST_PATH) $(PATH_OBJS) $(PATH_OBJS:.o=.Po) \
DATE_DEPFILES = $(DATE_OBJS:.o=.Po)
-include $(DATE_DEPFILES)
+ENVLIST_DEPFILES = $(ENVLIST_OBJS:.o=.Po)
+-include $(ENVLIST_DEPFILES)
+
GROUP_DEPFILES = $(GROUP_OBJS:.o=.Po)
-include $(GROUP_DEPFILES)
--- /dev/null
+/**
+ * @file
+ * Test code for envlist Operations
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "acutest.h"
+
+/******************************************************************************
+ * Add your test cases to this list.
+ *****************************************************************************/
+#define NEOMUTT_TEST_LIST \
+ NEOMUTT_TEST_ITEM(test_mutt_envlist_free) \
+ NEOMUTT_TEST_ITEM(test_mutt_envlist_getlist) \
+ NEOMUTT_TEST_ITEM(test_mutt_envlist_init) \
+ NEOMUTT_TEST_ITEM(test_mutt_envlist_set) \
+ NEOMUTT_TEST_ITEM(test_mutt_envlist_unset)
+
+/******************************************************************************
+ * You probably don't need to touch what follows.
+ *****************************************************************************/
+#define NEOMUTT_TEST_ITEM(x) void x(void);
+NEOMUTT_TEST_LIST
+#undef NEOMUTT_TEST_ITEM
+
+TEST_LIST = {
+#define NEOMUTT_TEST_ITEM(x) { #x, x },
+ NEOMUTT_TEST_LIST
+#undef NEOMUTT_TEST_ITEM
+ { 0 }
+};
--- /dev/null
+/**
+ * @file
+ * Test code for mutt_envlist_free()
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#define TEST_NO_MAIN
+#include "acutest.h"
+#include "config.h"
+#include "mutt/mutt.h"
+
+void test_mutt_envlist_free(void)
+{
+ // void mutt_envlist_free(void);
+}
--- /dev/null
+/**
+ * @file
+ * Test code for mutt_envlist_getlist()
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#define TEST_NO_MAIN
+#include "acutest.h"
+#include "config.h"
+#include "mutt/mutt.h"
+
+void test_mutt_envlist_getlist(void)
+{
+ // char **mutt_envlist_getlist(void);
+}
--- /dev/null
+/**
+ * @file
+ * Test code for mutt_envlist_init()
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#define TEST_NO_MAIN
+#include "acutest.h"
+#include "config.h"
+#include "mutt/mutt.h"
+
+void test_mutt_envlist_init(void)
+{
+ // void mutt_envlist_init(char *envp[]);
+}
--- /dev/null
+/**
+ * @file
+ * Test code for mutt_envlist_set()
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#define TEST_NO_MAIN
+#include "acutest.h"
+#include "config.h"
+#include "mutt/mutt.h"
+
+void test_mutt_envlist_set(void)
+{
+ // bool mutt_envlist_set(const char *name, const char *value, bool overwrite);
+}
--- /dev/null
+/**
+ * @file
+ * Test code for mutt_envlist_unset()
+ *
+ * @authors
+ * Copyright (C) 2019 Richard Russon <rich@flatcap.org>
+ *
+ * @copyright
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 2 of the License, or (at your option) any later
+ * version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#define TEST_NO_MAIN
+#include "acutest.h"
+#include "config.h"
+#include "mutt/mutt.h"
+
+void test_mutt_envlist_unset(void)
+{
+ // bool mutt_envlist_unset(const char *name);
+}