Commit Graph

42 Commits

Author SHA1 Message Date
c0887603c5 guile: avoid body duplication
In message, don't re-fill when unneeded. Add tests.

Fixes #2802.
2025-02-05 21:16:15 +02:00
606f4be74b guile: Fix the mu:body message method
Somewhere along the way, the body-txt and body-html fields were merged
into a single body field. Later, commit 8eac392221 ("guile: re-enable
the guile support") finally removed support for Field::Id::BodyHtml from
mu:c:get-field.

Unfortunately mu.scm and the documentation are still stuck in the past, so
update them. mu:body-txt is now a synonym for mu:body, and mu:body-html
always returns #f.

I wanted to add a mu:body test also for the rfc822.1 message, but there's
currently a bug where its body text is is duplicated (issue #2802), so the
test would fail.
2025-01-04 20:51:14 -03:00
a703f00214 guile: tests: Fix encoding of "atomic" message
It's stated to be US-ASCII with 7-bit encoding, but it contains the
UTF-8 character '—'.

Fixing the encoding very slightly changes the average size of messages
reported by mu:average, so adjust the new expected value.
2025-01-03 16:33:06 -03:00
fdce40af92 guile: separate guile load/extensions path 2024-03-10 10:28:11 +02:00
80745cbe29 Merge commit 'pullreqs/2635' 2024-03-10 10:27:46 +02:00
68822006c8 guile-tests: fix some typos 2024-02-26 18:31:10 +02:00
db6191e796 Fix guile_load_path to include build path
When meson is run in a build path that is different from source root, the
generated shared library cannot be found under "<source_root>/guile".  This
patch adds the corresponding path under build root to guile_root_path so that
they continue to work.

This should fix https://github.com/djcb/mu/issues/2631.
2024-02-25 17:24:43 -08:00
30b8238522 tests: move to tests/, make optional
While not recommended, sometimes it can be useful to disable building
the unit tests. This can be done now with
    meson -Dtests=disabled build
2024-01-06 18:35:22 +02:00
2f5602b938 unit tests: improve
and add a new one for the indexer
2023-09-12 21:38:57 +03:00
28b779efb8 mu-guile: fix guile-test build
upgrade to the new formatting code.

Fixes: #2540
2023-08-22 12:56:18 +03:00
5bf6fa399b guile: don't run test with asan builds
They're incompatible.
2022-12-29 12:25:58 +02:00
96b208d712 build: bump meson requirement to 56.0
We need some of the new functionality in the near-future.

Fix build warnings.
2022-12-19 23:01:16 +02:00
317fe53ff7 tests: update test helpers and users
Move test-mu-common to mu-test-utils. Use mu_test_init as a wrapper for
g_test_init. Update users.
2022-08-11 22:55:10 +03:00
8eac392221 guile: re-enable the guile support
Update for the internal (Mu::Message) APIs.

Update build.
2022-05-21 17:44:09 +03:00
de80b557e8 meson: build updates 2022-03-26 17:19:10 +02:00
3a7bfab5f5 guile: update unit tests
Make it work with meson.
2022-03-13 12:37:29 +02:00
ca5bb06457 guile: use mu-message-fields 2022-03-07 06:50:18 +02:00
ec826cd838 tests: update naming 2022-02-21 23:51:46 +02:00
48d3f9cfab tests: move to subdir, move to meson
De-clutter the source directories a bit. Ensure tests build with meson, and
remove from autotools in a few places (no need to do things twice).
2021-11-08 23:58:05 +02:00
3dd721d5a3 clang-format: update c/cc coding style
Update all cc code using .clang-format; please do so as well for future PRs
etc.; emacs has a handy 'clang-format' mode to make this automatic.

For comparing old changes with git blame, we can disregard this one using
--ignore-rev

(see https://www.moxio.com/blog/43/ignoring-bulk-change-commits-with-git-blame )
2021-10-20 12:26:16 +03:00
21374c12a1 guile: Fix and re-enable unit test 2021-03-17 18:33:05 +02:00
47454ad8d4 mu: add some missing files 2020-11-11 21:42:56 +02:00
3206b9db23 guile: use updated Query API 2020-11-07 11:43:11 +02:00
865f0ab9db guile: fix unit tests 2020-02-25 18:19:30 +02:00
20eea6153f fix guile build 2020-02-25 07:40:00 +02:00
be4860befe tests: update for lib/mu-store changes 2019-07-30 08:51:04 +03:00
052a228be7 add optional support for building with asan 2018-11-04 12:31:32 +02:00
aa70bf1920 Merge branch 'pr-1111'
Fix a bunch of conflicts, tests.
2018-08-18 10:29:40 +03:00
c0fce88540 fix file size in test-mu-guile.scm changed by e97ec2d5
Signed-off-by: Chirantan Ekbote <chirantan.ekbote@gmail.com>
2013-05-28 22:46:09 -07:00
cbe595483f * guile: update guile tests for slightly updated testcases 2013-05-15 00:18:05 +03:00
87e3c5d3f5 * cosmetic 2013-05-13 00:03:23 +03:00
1f24e224a9 * more more copyright year updates 2013-03-30 11:38:01 +02:00
855e81db99 * update copyright years 2013-03-30 11:32:07 +02:00
c5f8ea6451 * use AM_CPPFLAGS instead of INCLUDES 2012-12-22 22:54:50 +02:00
241af50e97 * update / add testcases for string normalization 2012-12-09 13:34:16 +02:00
30f93663b0 * lib: do some more escaping of body text 2012-11-18 22:09:56 +02:00
89b52d7eed * guile: update test case 2012-08-09 10:39:45 +03:00
543f4a1926 * guile: some more improvements 2012-07-15 12:44:52 +03:00
c613ef3c6e * guile: make unit test work on uninstalled mu-guile 2012-07-14 18:52:05 +03:00
8e3fbe380e * guile: some general improvements / cleanups in module loading, object
visibilty. turn some integers (such as message priority, log level, contact
  type) into symbols.
2012-07-14 12:32:15 +03:00
fcb202d618 * guile: unit tests improvement (don't require installation) 2012-07-12 21:59:14 +03:00
9bddf2f0b9 * guile: beginnings of some unit tests 2012-07-12 21:19:59 +03:00