about summary refs log tree commit diff stats
path: root/tests/unittests
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #1842 from H3rnand3zzz/feature/plugins-downloadMichael Vetter2023-06-062-0/+21
|\ | | | | New Feature: Plugins Download
| * Add url support (downloading) to `/plugins install`John Hernandez2023-05-162-0/+21
| | | | | | | | Additional changes include code refactoring.
* | Merge branch 'master' into cleanup/gchar-charMichael Vetter2023-05-111-0/+4
|\ \
| * | fix `/reconnect now`Steffen Jaeckel2023-05-101-0/+4
| |/ | | | | | | | | | | | | This fixes #1846 Issue introduced by a0aa26b6fa65ba625f4a6d3495a345c7120ff16d Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* / Cleanup: gchar as gchar instead of charJohn Hernandez2023-05-043-12/+10
|/ | | | | | | | Use gchar instead of char in most of the cases where gchar is intended. Reason: improve compatibility and stability. Issue #1819 Minor refactoring.
* Add ability to disable avatar publishingIsaacM882023-05-021-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add "/avatar disable" to comply with point "3.5 Publisher Disables Avatar Publishing" in XEP-0084. src/command/cmd_defs.c:2416 Add "disable" argument. Reword the "/avatar" command description so it flows better. src/command/cmd_ac.c:1101 Add "disable" to the "/avatar" autocomplete dictionary. src/command/cmd_funcs.c:9277 Split "/avatar" commands into two groups with an if statement; those with a parameter and those without. "cons_bad_cmd_usage()" is in both groups, which is messy. "disable" has similar logic to "set", but it includes a failure message. src/xmpp/avatar.c:152 "avatar_publishing_disable()" uses the same logic to publish metadata as in "avatar_set()". src/xmpp/avatar.c:238 Add a message to inform users when they do not receive an avatar after using "/avatar get" and "/avatar open". In case of a failure, the user will be subscribed to future avatar updates as long as they continue to use their current instance of profanity. Adding "caps_remove_feature()" after "cons_show()" will unsubscribe the user from avatar updates and prevent the user from downloading an avatar unexpectedly hours later without issuing an "/avatar" command. src/xmpp/stanza.c:2698 The new "disable" function follows the same logic as "stanza_create_avatar_metadata_publish_iq()".
* Add sessions_alarmJohn Hernandez2023-04-186-18/+26
| | | | | | | | | Introduce new feature: sessions_alarm. Added new account setting: max_connections. On exceeding this number, user will get an alert. If number is less than 1, no alert will happen. Tests altered to fit new feature.
* Add nickname support for /roster removeJohn Hernandez2023-04-133-0/+24
| | | | | | Add support of name/nickname instead of only JID for `/roster remove` command. Add tests for it as well.
* Allow setting client identification name/version manuallyJohn Hernandez2023-04-096-18/+26
| | | | | | | | Add changes allowing user to switch client name and version. Useful for enhancing user privacy. Minor cleanup.
* Merge pull request #1808 from ↵Michael Vetter2023-04-031-0/+4
|\ | | | | | | | | MarcoPolo-PasTonMolo/fix/empty_window_after_reconnect Fix empty window after reconnect
| * Fix empty window after reconnectMarcoPolo-PasTonMolo2023-04-021-0/+4
| | | | | | | | | | | | | | | | Sometimes after a reconnect the current window would get cleared. This was a deliberate change to fix the profanity window looking all garbled up after providing the passphrase for a gpg key using pinentry-curses. Fixes https://github.com/profanity-im/profanity/issues/1556
* | Fix typos and update codespell configurationDaniel Santos2023-04-031-2/+2
|/ | | | | | | | | | * Fix typos. * Add words that are not typos to codespell's ignore words list and ignore regex. * Make codespell ignore URIs. * Make `make doublecheck` throw no error. Signed-off-by: Daniel Santos <dacs.git@brilhante.top>
* add test-case for #1761Steffen Jaeckel2023-03-113-0/+24
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Fix duplicate download IDs.IsaacM882023-03-093-1/+3
| | | | | | | | | | Fixes https://github.com/profanity-im/profanity/issues/1794 Explanation The problem is the download's identifier. Downloads are given an ID so they can be referenced later when their progress changes. Currently, the download's ID is the download's URL. When you download the same file twice, you have two downloads with the same ID. Download progress updates are shown on the first of both downloads with the same ID. Solution Change the download's ID from its URL to a random number. A random ID is generated when get_random_string() is called from cmd_funcs.c. Several other functions are updated to cope with the new ID format.
* let `account_new()` take ownership of passed valuesSteffen Jaeckel2023-01-185-34/+34
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* add `now` option to `/reconnect` commandSteffen Jaeckel2023-01-181-0/+4
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* minor changesSteffen Jaeckel2023-01-181-3/+3
| | | | | | | | | | | * fix typo * less code duplication * less `GString` usage * more `auto_gchar` usage * document connecting to servers supporting SASL ANONYMOUS * ignore valgrind output Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* add `/strophe` command to modify libstrophe-specific settingsSteffen Jaeckel2023-01-181-0/+5
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Update copyright yearMichael Vetter2023-01-101-1/+1
|
* Add MAM test stubsMichael Vetter2022-10-212-0/+6
|
* Add vCard supportMarouane L2022-10-183-0/+88
| | | | | | | | | | | | Only nicknames, photos, birthdays, addresses, telephone numbers, emails, JIDs, titles, roles, notes, and URLs are supported Due to the synopsis array not having enough space, `/vcard photo open-self` and `/vcard photo save-self` are not documented properly in the synopsis section of the `/vcard` command, but they are documented in the arguments section Fixed memory leak in vcard autocomplete (thanks to debXwoody)
* Split ox functions from gpg.c to ox.cMichael Vetter2022-06-292-18/+21
|
* add chatlog unittestMichael Vetter2022-06-283-65/+93
|
* Display mood preferencesMichael Vetter2022-06-221-0/+5
|
* Don't forget encryption status for OX and PGP.MarcoPolo-PasTonMolo2022-06-176-18/+28
| | | | | | | | Use a pgp.enabled and ox.enabled array the same way that omemo.enabled is used. Fixes https://github.com/profanity-im/profanity/issues/1694 Fixes https://github.com/profanity-im/profanity/issues/733
* Use our omemo sid/fingerprint in qr codeMichael Vetter2022-05-312-1/+7
| | | | | | | Current clients sid/fingerprint will be shown in following format: `xmpp:<user@server>?omemo-sid-<numerical-sid>=<omemo-fingerprint-hex-string>` Fix https://github.com/profanity-im/profanity/issues/1320
* Add basic qrcode functionsMichael Vetter2022-05-301-0/+11
|
* Final touches for `/avatar set`Michael Vetter2022-05-271-2/+0
|
* Add checks for whether gdk-pixbuf exists before using avatar setMarcoPolo-PasTonMolo2022-05-261-1/+4
|
* Add `/avatar set` command to publish avatarMarcoPolo-PasTonMolo2022-05-261-0/+5
| | | | | | | | Use `/avatar set <path>` where <path> is an image file to upload a new avatar for the current user. When the avatar is too big it gets scaled down. Scaling code copied from dino. Fixes https://github.com/profanity-im/profanity/issues/1687
* Update copyright yearMichael Vetter2022-05-091-1/+1
|
* ox: show ox preferencesMichael Vetter2022-05-051-0/+4
|
* Fix preferences testsMichael Vetter2022-04-081-2/+2
|
* less duplicationSteffen Jaeckel2022-03-311-1/+2
| | | | | | | | Print error message from `_string_matches_one_of()` instead of forming an error message manually that contains the same entries that were checked in `_string_matches_one_of()`. Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Merge pull request #1652 from profanity-im/fix-1624Michael Vetter2022-03-232-2/+57
|\ | | | | Fix #1624
| * add profanity-specific CAfileSteffen Jaeckel2022-03-221-0/+55
| | | | | | | | | | | | | | | | The profanity-internal mechanism to allow connecting to a server isn't easily portable to cURL. Therefor introduce a profanity-specific CAfile which is managed individually and will be configured in libcurl calls. Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
| * a tad more `const`-correctnessSteffen Jaeckel2022-03-221-2/+2
| | | | | | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* | Add quote autocompletion for previous messagesMarcoPolo-PasTonMolo2022-03-211-0/+7
|/ | | | | | | | | | Fixes https://github.com/profanity-im/profanity/issues/1649 Type `>` then press tab or shift tab to autocomplete previous messages, then type your reply and send message. Newlines are replaced with newline followed by `> `. A newline is added at the end so that the user can immediately type a message without manually adding a new line.
* use `g_mkdir_with_parents()` instead of home-baked solutionSteffen Jaeckel2022-03-141-2/+2
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* auto-formatSteffen Jaeckel2022-02-011-2/+2
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* tests: add publish_user_mood stubMichael Vetter2021-12-061-0/+5
|
* tests: Add win_get_last_sent_messag() stubMichael Vetter2021-10-221-0/+5
|
* Format new register code correctlyMichael Vetter2021-10-131-1/+1
|
* registration: add test stubMichael Vetter2021-10-131-0/+12
|
* Format code correctlyMichael Vetter2021-10-052-9/+13
|
* Fix: files missing final ending newlinea13460542021-08-264-4/+4
|
* Add silence test stubMichael Vetter2021-07-011-0/+6
|
* Merge pull request #1569 from profanity-im/feature/1434-spam-reportingMichael Vetter2021-07-011-1/+1
|\ | | | | Add XEP-0377: Spam Reporting
| * Adjust test stub of blocking commandMichael Vetter2021-07-011-1/+1
| |
* | Restore last status string when connectingThorben Günther2021-07-011-0/+6
| |