From 7c591049bee99b0142ff307c9d863acbed4f3d65 Mon Sep 17 00:00:00 2001 From: Billy Chan Date: Thu, 15 Sep 2022 16:18:13 +0800 Subject: [PATCH] Add docs --- tests/type_tests.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/type_tests.rs b/tests/type_tests.rs index 5ceaf511..4225b080 100644 --- a/tests/type_tests.rs +++ b/tests/type_tests.rs @@ -2,6 +2,18 @@ pub mod common; use sea_orm::{IntoActiveValue, TryFromU64, TryGetable, Value}; +/* + +When supporting a new type in SeaORM we should implement the following traits for it: + - `IntoActiveValue`, given that it implemented `Into` already + - `TryGetable` + - `TryFromU64` + +Also, we need to update `impl FromQueryResult for JsonValue` at `src/query/json.rs` +to correctly serialize the type as `serde_json::Value`. + +*/ + pub fn it_impl_into_active_value, V: Into>() {} pub fn it_impl_try_getable() {}