@Test
  @Transactional
  public void createPhysiotherapist() throws Exception {
    int databaseSizeBeforeCreate = physiotherapistRepository.findAll().size();

    // Create the Physiotherapist

    restPhysiotherapistMockMvc
        .perform(
            post("/api/physiotherapists")
                .contentType(TestUtil.APPLICATION_JSON_UTF8)
                .content(TestUtil.convertObjectToJsonBytes(physiotherapist)))
        .andExpect(status().isCreated());

    // Validate the Physiotherapist in the database
    List<Physiotherapist> physiotherapists = physiotherapistRepository.findAll();
    assertThat(physiotherapists).hasSize(databaseSizeBeforeCreate + 1);
    Physiotherapist testPhysiotherapist = physiotherapists.get(physiotherapists.size() - 1);
    assertThat(testPhysiotherapist.getFirstName()).isEqualTo(DEFAULT_FIRST_NAME);
    assertThat(testPhysiotherapist.getLastName()).isEqualTo(DEFAULT_LAST_NAME);
    assertThat(testPhysiotherapist.getStreet()).isEqualTo(DEFAULT_STREET);
    assertThat(testPhysiotherapist.getPostalCode()).isEqualTo(DEFAULT_POSTAL_CODE);
    assertThat(testPhysiotherapist.getCity()).isEqualTo(DEFAULT_CITY);
    assertThat(testPhysiotherapist.getCountry()).isEqualTo(DEFAULT_COUNTRY);
  }
  @Test
  @Transactional
  public void updatePhysiotherapist() throws Exception {
    // Initialize the database
    physiotherapistRepository.saveAndFlush(physiotherapist);

    int databaseSizeBeforeUpdate = physiotherapistRepository.findAll().size();

    // Update the physiotherapist
    physiotherapist.setFirstName(UPDATED_FIRST_NAME);
    physiotherapist.setLastName(UPDATED_LAST_NAME);
    physiotherapist.setStreet(UPDATED_STREET);
    physiotherapist.setPostalCode(UPDATED_POSTAL_CODE);
    physiotherapist.setCity(UPDATED_CITY);
    physiotherapist.setCountry(UPDATED_COUNTRY);

    restPhysiotherapistMockMvc
        .perform(
            put("/api/physiotherapists")
                .contentType(TestUtil.APPLICATION_JSON_UTF8)
                .content(TestUtil.convertObjectToJsonBytes(physiotherapist)))
        .andExpect(status().isOk());

    // Validate the Physiotherapist in the database
    List<Physiotherapist> physiotherapists = physiotherapistRepository.findAll();
    assertThat(physiotherapists).hasSize(databaseSizeBeforeUpdate);
    Physiotherapist testPhysiotherapist = physiotherapists.get(physiotherapists.size() - 1);
    assertThat(testPhysiotherapist.getFirstName()).isEqualTo(UPDATED_FIRST_NAME);
    assertThat(testPhysiotherapist.getLastName()).isEqualTo(UPDATED_LAST_NAME);
    assertThat(testPhysiotherapist.getStreet()).isEqualTo(UPDATED_STREET);
    assertThat(testPhysiotherapist.getPostalCode()).isEqualTo(UPDATED_POSTAL_CODE);
    assertThat(testPhysiotherapist.getCity()).isEqualTo(UPDATED_CITY);
    assertThat(testPhysiotherapist.getCountry()).isEqualTo(UPDATED_COUNTRY);
  }