public static Task CreateInvalidGenre()
        {
            var connectionString = ConnectivityService.GetConnectionString("TEMP");
            var context          = new BookOrganizer2DbContext(connectionString);
            var repository       = new GenreRepository(context);
            var genreService     = new GenreService(repository);

            var genreId = new GenreId(SequentialGuid.NewSequentialGuid());
            var command = new Commands.Create {
                Id = genreId
            };

            return(genreService.Handle(command));
        }
        public static async Task <Genre> CreateValidGenre()
        {
            var connectionString = ConnectivityService.GetConnectionString("TEMP");
            var context          = new BookOrganizer2DbContext(connectionString);
            var repository       = new GenreRepository(context);

            var genreService = new GenreService(repository);

            var command = new Commands.Create
            {
                Id   = new GenreId(SequentialGuid.NewSequentialGuid()),
                Name = "sci-fi"
            };

            await genreService.Handle(command);

            return(await repository.GetAsync(command.Id));
        }