Temp mock push #39
Annotations
10 errors and 10 warnings
src/api/../tests/api/ecdar_api.rs#L4
error[E0432]: unresolved imports `crate::api::ecdar_api::MockConcreteEcdarApi`, `crate::api::ecdar_api::MockConcreteEcdarApi_EcdarBackend`
--> src/api/../tests/api/ecdar_api.rs:4:25
|
4 | handle_session, MockConcreteEcdarApi, MockConcreteEcdarApi_EcdarBackend,
| ^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `MockConcreteEcdarApi_EcdarBackend` in `api::ecdar_api`
| |
| no `MockConcreteEcdarApi` in `api::ecdar_api`
| help: a similar name exists in the module: `ConcreteEcdarApi`
|
src/api/../tests/api/ecdar_api.rs#L22
error[E0432]: unresolved import `crate::database::user_context::MockUserContextTrait`
--> src/api/../tests/api/ecdar_api.rs:22:9
|
22 | use crate::database::user_context::MockUserContextTrait;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------------------
| | |
| | help: a similar name exists in the module: `UserContextTrait`
| no `MockUserContextTrait` in `database::user_context`
|
src/api/../tests/api/ecdar_api.rs#L32
error[E0433]: failed to resolve: use of undeclared crate or module `user`
--> src/api/../tests/api/ecdar_api.rs:32:66
|
32 | async fn delete(&self, entity_id: i32) -> Result<user::Model, DbErr>;
| ^^^^
| |
| use of undeclared crate or module `user`
| help: a struct with a similar name exists (notice the capitalization): `User`
|
= help: consider importing this module:
crate::entities::user
|
src/api/../tests/api/ecdar_api.rs#L32
error[E0412]: cannot find type `DbErr` in this scope
--> src/api/../tests/api/ecdar_api.rs:32:79
|
32 | async fn delete(&self, entity_id: i32) -> Result<user::Model, DbErr>;
| ^^^^^ not found in this scope
|
= help: consider importing one of these items:
migration::DbErr
sea_orm::DbErr
|
src/api/../tests/api/ecdar_api.rs#L31
error[E0433]: failed to resolve: use of undeclared crate or module `user`
--> src/api/../tests/api/ecdar_api.rs:31:37
|
31 | impl EntityContextTrait<user::Model> for C {
| ^^^^ use of undeclared crate or module `user`
|
help: a struct with a similar name exists
|
31 | impl EntityContextTrait<User::Model> for C {
| ~~~~
help: consider importing this module
|
3 + use crate::entities::user;
|
|
src/api/../tests/api/ecdar_api.rs#L32
error[E0433]: failed to resolve: use of undeclared crate or module `user`
--> src/api/../tests/api/ecdar_api.rs:32:66
|
32 | async fn delete(&self, entity_id: i32) -> Result<user::Model, DbErr>;
| ^^^^ use of undeclared crate or module `user`
|
help: a struct with a similar name exists
|
32 | async fn delete(&self, entity_id: i32) -> Result<User::Model, DbErr>;
| ~~~~
help: consider importing this module
|
3 + use crate::entities::user;
|
|
src/api/../tests/api/ecdar_api.rs#L32
error[E0412]: cannot find type `DbErr` in this scope
--> src/api/../tests/api/ecdar_api.rs:32:79
|
32 | async fn delete(&self, entity_id: i32) -> Result<user::Model, DbErr>;
| ^^^^^ not found in this scope
|
help: consider importing one of these items
|
3 + use migration::DbErr;
|
3 + use sea_orm::DbErr;
|
|
src/api/../tests/api/ecdar_api.rs#L396
error[E0425]: cannot find value `MockEcdarBackend` in this scope
--> src/api/../tests/api/ecdar_api.rs:396:56
|
396 | let api = get_mock_concrete_ecdar_api(Arc::new(MockEcdarBackend)).await;
| ^^^^^^^^^^^^^^^^ not found in this scope
|
src/api/../tests/api/ecdar_api.rs#L31
error[E0277]: `api::ecdar_api::tests::ecdar_api::delete_user_nonexistent_user_returns_err::{closure#0}::MockC` doesn't implement `std::fmt::Debug`
--> src/api/../tests/api/ecdar_api.rs:31:54
|
31 | impl EntityContextTrait<user::Model> for C {
| ^ `api::ecdar_api::tests::ecdar_api::delete_user_nonexistent_user_returns_err::{closure#0}::MockC` cannot be formatted using `{:?}`
|
= help: the trait `std::fmt::Debug` is not implemented for `api::ecdar_api::tests::ecdar_api::delete_user_nonexistent_user_returns_err::{closure#0}::MockC`
= note: add `#[derive(Debug)]` to `api::ecdar_api::tests::ecdar_api::delete_user_nonexistent_user_returns_err::{closure#0}::MockC` or manually `impl std::fmt::Debug for api::ecdar_api::tests::ecdar_api::delete_user_nonexistent_user_returns_err::{closure#0}::MockC`
note: required by a bound in `database::entity_context::EntityContextTrait`
--> src/database/entity_context.rs:9:48
|
9 | pub trait EntityContextTrait<T>: Send + Sync + Debug {
| ^^^^^ required by this bound in `EntityContextTrait`
|
src/tests/api/helpers.rs#L4
error[E0432]: unresolved import `crate::api::reveaal_context::MockReveaalContext`
--> src/tests/api/helpers.rs:4:5
|
4 | use crate::api::reveaal_context::MockReveaalContext;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------------------
| | |
| | help: a similar name exists in the module: `ReveaalContext`
| no `MockReveaalContext` in `api::reveaal_context`
|
src/api/ecdar_api.rs#L1
warning: unused import: `std::env`
--> src/api/ecdar_api.rs:1:5
|
1 | use std::env;
| ^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
|
src/api/ecdar_api.rs#L8
warning: unused import: `mockall::automock`
--> src/api/ecdar_api.rs:8:5
|
8 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/api/ecdar_api.rs#L1
warning: unused import: `std::env`
--> src/api/ecdar_api.rs:1:5
|
1 | use std::env;
| ^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
|
src/api/ecdar_api.rs#L8
warning: unused import: `mockall::automock`
--> src/api/ecdar_api.rs:8:5
|
8 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/api/reveaal_context.rs#L8
warning: unused import: `mockall::automock`
--> src/api/reveaal_context.rs:8:5
|
8 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/api/reveaal_context.rs#L8
warning: unused import: `mockall::automock`
--> src/api/reveaal_context.rs:8:5
|
8 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/database/session_context.rs#L2
warning: unused import: `mockall::automock`
--> src/database/session_context.rs:2:5
|
2 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/database/session_context.rs#L2
warning: unused import: `mockall::automock`
--> src/database/session_context.rs:2:5
|
2 | use mockall::automock;
| ^^^^^^^^^^^^^^^^^
|
src/database/session_context.rs#L67
warning: returning the result of a `let` binding from a block
--> src/database/session_context.rs:67:9
|
66 | let session = session.insert(&self.db_context.get_connection()).await;
| ---------------------------------------------------------------------- unnecessary `let` binding
67 | session
| ^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return
= note: `#[warn(clippy::let_and_return)]` on by default
help: return the expression directly
|
66 ~
67 ~ session.insert(&self.db_context.get_connection()).await
|
|
src/database/user_context.rs#L4
warning: unused imports: `automock`, `mock`
--> src/database/user_context.rs:4:15
|
4 | use mockall::{automock, mock};
| ^^^^^^^^ ^^^^
|
The logs for this run have expired and are no longer available.
Loading