feat(personalized_feed): fixed photos rendering and fixed profile posts rendering

This commit is contained in:
misha
2026-07-23 15:17:01 +03:00
parent c8c8ade083
commit a6fe6afb80
13 changed files with 491 additions and 406 deletions

View File

@@ -150,6 +150,19 @@ void main() {
expect(model.videoUrlThumb, 'media/1/thumb.jpg');
});
test('parses profile search_by_author fixture with gallery and video', () {
final posts = FeedFixtures.blogPostsByAuthor();
expect(posts, hasLength(2));
expect(posts.first.images, hasLength(2));
expect(posts.first.images.first.orientation, 'horizontal');
expect(posts.first.images[1].orientation, 'vertical');
expect(posts.first.videoEmbedUrl, contains('rutube.ru/play/embed'));
expect(posts.first.videoUrlThumb, 'media/1/thumb.jpg');
expect(posts[1].images, hasLength(2));
expect(posts[1].videoEmbedUrl, isNull);
});
test('creates FeedBlogPostModel with different states', () {
const author = Author(
authorSlug: 'author',