Package org.xrace.model.evenements

Examples of org.xrace.model.evenements.Course


  public final void testSaveValidateMinMaxEquipes1()
  {
    try
    {
      Course course = createCourse();
      course.setCourseParEquipe(true);
      getCourseService().save(course);

      fail();
    }
    catch (final ValidationException vex)
View Full Code Here


  public final void testSaveValidateMinMaxEquipes2()
  {
    try
    {
      Course course = createCourse();
      course.setCourseParEquipe(true);
      course.setMinParticipantsEquipe(-1);
      course.setMaxParticipantsEquipe(3);
      getCourseService().save(course);

      fail();
    }
    catch (final ValidationException vex)
View Full Code Here

  public final void testSaveValidateMinMaxEquipes3()
  {
    try
    {
      Course course = createCourse();
      course.setCourseParEquipe(true);
      course.setMinParticipantsEquipe(3);
      course.setMaxParticipantsEquipe(1);
      getCourseService().save(course);

      fail();
    }
    catch (final ValidationException vex)
View Full Code Here

  public final void testSaveValidateMinMaxEquipes4()
  {
    try
    {
      Course course = createCourse();
      course.setCourseParEquipe(true);
      course.setMinParticipantsEquipe(3);
      course.setMaxParticipantsEquipe(0);
      getCourseService().save(course);

      fail();
    }
    catch (final ValidationException vex)
View Full Code Here

    }
  }

  public void testSaveValidateEnsemblesPucesNoError()
  {
    Course course = getCourseService().getCourseParNom(evenement,
        "Cross-Country");
    getCourseService().save(course);
  }
View Full Code Here

    getCourseService().save(course);
  }

  public void testSaveValidateEnsemblesPucesVide()
  {
    Course course = getCourseService().getCourseParNom(evenement,
        "Downhill");
    getCourseService().save(course);
  }
View Full Code Here

    getCourseService().save(course);
  }

  public void testSaveValidateEnsemblesPucesDouble()
  {
    Course course = getCourseService().getCourseParNom(evenement,
        "Cross-Country");

    CourseEnsemblePuces cep = new CourseEnsemblePuces();
    cep.setCourse(course);
    cep.setEnsemblePuces(getEnsemblePucesService().findByCode("ENS1"));
View Full Code Here

    }
  }

  public final void testDeleteCourseInvalid()
  {
    final Course course = getCourseService().getCourseParNom(evenement,
        "Cross-Country");
    getCourseService().delete(course);
    this.flush(getCourseService(), RuntimeException.class);
  }
View Full Code Here

    this.flush(getCourseService(), RuntimeException.class);
  }

  public final void testDeleteCourse()
  {
    final Course autreCourse = getCourseService().getCourseParNom(
        evenement, "Downhill");

    getCourseService().delete(autreCourse);

    Assert.assertNull(getCourseService().getCourseParNom(evenement,
View Full Code Here

        "Downhill"));
  }

  public void testAssignPuces()
  {
    Course course = getCourseService().getCourseParNom(evenement,
        "Cross-Country");
    getCourseService().assignPuces(course);

    for (Inscription inscription : course.getInscriptions())
    {
      assertTrue(StringUtils.isNotBlank(inscription.getCodePuce()));
      assertNotNull(inscription.getNumeroPuce());
    }
  }
View Full Code Here

TOP

Related Classes of org.xrace.model.evenements.Course

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.