aboutsummaryrefslogtreecommitdiff
path: root/tests/test_msg_builder.rs
Commit message (Collapse)AuthorAgeFilesLines
* Move unit tests into sourceZeyla Hellyer2018-08-011-77/+0
| | | | | | | | | Move the unit tests into the relevant source files. There's no need for them to be seprate, especially when the `tests` directory is meant to be for integration tests. The deserialization tests that include JSON files are still in the `tests` dir, along with the public prelude re-export tests.
* Add `animated` to `Emoji` and `ReactionType`Zeyla Hellyer2017-12-201-0/+1
| | | | | | | | | | Adds an animated structfield to `Emoji` and `ReactionType`'s `Custom` variant, which defaults to false if not present. A test has been added for deserializing it, taken from a REST API GET Emojis response. (cherry picked from commit 5286949f424e824784344ebb7b7af4e52fb819c3)
* Fix most clippy lints, take more refeerncesZeyla Hellyer2017-12-161-2/+2
| | | | | Fix clippy lints and subsequently accept references for more function parameters.
* Break up the model moduleZeyla Hellyer2017-12-161-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `model` module has historically been one giant module re-exporting all of the model types, which is somewhere around 100 types. This can be a lot to look at for a new user and somewhat overwhelming, especially with a large number of fine-grained imports from the module. The module is now neatly split up into submodules, mostly like it has been internally since the early versions of the library. The submodules are: - application - channel - error - event - gateway - guild - id - invite - misc - permissions - prelude - user - voice - webhook Each submodule contains types that are "owned" by the module. For example, the `guild` submodule contains, but not limited to, Emoji, AuditLogsEntry, Role, and Member. `channel` contains, but not limited to, Attachment, Embed, Message, and Reaction. Upgrade path: Instead of glob importing the models via `use serenity::model::*;`, instead glob import via the prelude: ```rust use serenity::model::prelude::*; ``` Instead of importing from the root model module: ```rust use serenity::model::{Guild, Message, OnlineStatus, Role, User}; ``` instead import from the submodules like so: ```rust use serenity::model::channel::Message; use serenity::model::guild::{Guild, Role}; use serenity::model::user::{OnlineStatus, User}; ```
* Change the config a bit, and a few nitpicksacdenisSK2017-07-271-6/+6
|
* rustfmtacdenisSK2017-07-271-11/+9
|
* Fix no-feature testsZeyla Hellyer2017-06-241-2/+2
|
* Add Content for MessageBuilderSkye2017-05-301-0/+26
| | | Allow `push` and `push_safe` to use a flexible syntax for formatting.
* Fix some clippy lintsZeyla Hellyer2017-02-281-2/+2
|
* Improve Mentions, fix MessageBuilderIllia2016-12-061-0/+53
Remove the obsolete Mention struct as well as related methods, improve the way mentioning works, fix the message builder, add a test for all this.