Skip to content

Commit

Permalink
test: improve generate models
Browse files Browse the repository at this point in the history
  • Loading branch information
deandreamatias committed Feb 18, 2024
1 parent 10daac4 commit 84eb468
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/helpers/generate_tvshow.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class GenerateTvshow {
inProduction: _faker.randomGenerator.boolean() ? 1 : 0,
name: _faker.lorem.sentence(),
numberOfEpisodes: _faker.randomGenerator.integer(999),
numberOfSeasons: _faker.randomGenerator.integer(50),
numberOfSeasons: _faker.randomGenerator.integer(50, min: 1),
overview: _faker.lorem.sentence(),
posterPath: _faker.internet.httpsUrl(),
rowId:
Expand All @@ -25,14 +25,14 @@ class GenerateTvshow {
episodeNumber: _faker.randomGenerator.integer(50),
name: _faker.lorem.sentence(),
id: _faker.randomGenerator.integer(50),
seasonNumber: _faker.randomGenerator.integer(50),
seasonNumber: _faker.randomGenerator.integer(50, min: 1),
);

List<TvshowDetails> get tvshows =>
random.amount<TvshowDetails>((i) => tvshowDetails, 50);

TvshowSeasonsDetails get tvshowSeasonsDetails => TvshowSeasonsDetails(
seasonNumber: _faker.randomGenerator.integer(99),
seasonNumber: _faker.randomGenerator.integer(99, min: 1),
episodes: random.amount<Episode>((i) => episode, 50),
id: _faker.randomGenerator.integer(9999),
name: _faker.lorem.sentence(),
Expand Down

0 comments on commit 84eb468

Please sign in to comment.