Uploaded image for project: 'Causeway'
  1. Causeway
  2. CAUSEWAY-3502

[NOT A PROBLEM] MM validation is incorrect on autoComplete/choices

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • 2.0.0-RC1
    • 2.0.0-RC2
    • Core
    • None

    Description

      check out branch CAUSEWAY-3502-reproduce from the simpleapp starter app (this is branched off of jpa-SNAPSHOT)

      NB: updated to useĀ 

          /**
           * following method results in:
           *
           * org.opentest4j.AssertionFailedError:
           * domainapp.modules.simple.dom.so.SimpleObject#changeOrderDetails[2] has no choices nor autoComplete, yet represents a domain-object or is a plural.
           * domainapp.modules.simple.dom.so.SimpleObject#changeOrderDetails[1] has no choices nor autoComplete, yet represents a domain-object or is a plural.
           */
      
          @Action(semantics = SemanticsOf.IDEMPOTENT)
          public SimpleObject changeOrderDetails(
                  final String orderNumber,
                  final SimpleObject buyer,
                  final SimpleObject supplier,
                  final String sellerOrderReference,
                  final LocalDate orderDate
          ) {
              return this;
          }
          public List<SimpleObject> autoComplete1ChangeOrderDetails(@MinLength(3) final String searchPhrase) {
              return Collections.emptyList();
          }
          // this form also fails:
      //    public List<SimpleObject> autoComplete1ChangeOrderDetails(final String orderNumber, @MinLength(3) final String searchPhrase) {
      //        return Collections.emptyList();
      //    }
          public String validate1ChangeOrderDetails(final String orderNumber, final SimpleObject party) {
              return null;
          }
          public List<SimpleObject> autoComplete2ChangeOrderDetails(
                  @MinLength(3) final String searchPhrase) {
              return Collections.emptyList();
          }
          // this form also fails:
      //    public List<SimpleObject> autoComplete2ChangeOrderDetails(
      //            final String orderNumber, final SimpleObject buyer, @MinLength(3) final String searchPhrase) {
      //        return Collections.emptyList();
      //    }
          public String validate2ChangeOrderDetails(final String orderNumber, final SimpleObject buyer, final SimpleObject supplier) {
              return null;
          }
       

      Attachments

        Activity

          People

            hobrom Andi Huber
            danhaywood Daniel Keir Haywood
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: