content: package com.konsol.beatstream.domain;
  
  import static org.assertj.core.api.Assertions.assertThat;
  
  public class TrackAsserts {
  
      /**
       * Asserts that the entity has all properties (fields/relationships) set.
       *
       * @param expected the expected entity
       * @param actual the actual entity
       */
      public static void assertTrackAllPropertiesEquals(Track expected, Track actual) {
          assertTrackAutoGeneratedPropertiesEquals(expected, actual);
          assertTrackAllUpdatablePropertiesEquals(expected, actual);
      }
  
      /**
       * Asserts that the entity has all updatable properties (fields/relationships) set.
       *
       * @param expected the expected entity
       * @param actual the actual entity
       */
      public static void assertTrackAllUpdatablePropertiesEquals(Track expected, Track actual) {
          assertTrackUpdatableFieldsEquals(expected, actual);
          assertTrackUpdatableRelationshipsEquals(expected, actual);
      }
  
      /**
       * Asserts that the entity has all the auto generated properties (fields/relationships) set.
       *
       * @param expected the expected entity
       * @param actual the actual entity
       */
      public static void assertTrackAutoGeneratedPropertiesEquals(Track expected, Track actual) {
          assertThat(expected)
              .as("Verify Track auto generated properties")
              .satisfies(e -> assertThat(e.getId()).as("check id").isEqualTo(actual.getId()));
      }
  
      /**
       * Asserts that the entity has all the updatable fields set.
       *
       * @param expected the expected entity
       * @param actual the actual entity
       */
      public static void assertTrackUpdatableFieldsEquals(Track expected, Track actual) {
          assertThat(expected)
              .as("Verify Track relevant properties")
              .satisfies(e -> assertThat(e.getTitle()).as("check title").isEqualTo(actual.getTitle()))
              .satisfies(e -> assertThat(e.getDuration()).as("check duration").isEqualTo(actual.getDuration()))
              .satisfies(e -> assertThat(e.getLiked()).as("check liked").isEqualTo(actual.getLiked()))
              .satisfies(e -> assertThat(e.getAudioFileId()).as("check audioFileId").isEqualTo(actual.getAudioFileId()))
              .satisfies(e -> assertThat(e.getCoverImageFileId()).as("check coverImageFileId").isEqualTo(actual.getCoverImageFileId()));
      }
  
      /**
       * Asserts that the entity has all the updatable relationships set.
       *
       * @param expected the expected entity
       * @param actual the actual entity
       */
      public static void assertTrackUpdatableRelationshipsEquals(Track expected, Track actual) {
          assertThat(expected)
              .as("Verify Track relationships")
              .satisfies(e -> assertThat(e.getArtist()).as("check artist").isEqualTo(actual.getArtist()))
              .satisfies(e -> assertThat(e.getAlbum()).as("check album").isEqualTo(actual.getAlbum()));
      }
  }
  