mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-04-22 20:38:02 +00:00
Improve UI test coverage
With this commit I believe I've covered all `compile_error!`-based errors.
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
#[macro_use]
|
||||
extern crate serde_derive;
|
||||
|
||||
#[derive(Serialize)]
|
||||
struct S {
|
||||
#[serde(bound(unknown))]
|
||||
x: (),
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
@@ -0,0 +1,8 @@
|
||||
error: malformed bound attribute, expected `bound(serialize = ..., deserialize = ...)`
|
||||
--> $DIR/bound.rs:6:19
|
||||
|
|
||||
6 | #[serde(bound(unknown))]
|
||||
| ^^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
#[macro_use]
|
||||
extern crate serde_derive;
|
||||
|
||||
#[derive(Serialize)]
|
||||
struct S {
|
||||
#[serde(rename(unknown))]
|
||||
x: (),
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
@@ -0,0 +1,8 @@
|
||||
error: malformed rename attribute, expected `rename(serialize = ..., deserialize = ...)`
|
||||
--> $DIR/rename.rs:6:20
|
||||
|
|
||||
6 | #[serde(rename(unknown))]
|
||||
| ^^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
Reference in New Issue
Block a user