/*
 * Copyright (c) 2021 - Manifold Systems LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package manifold.ext.props.multi;

import org.junit.Test;

public class MultiTest
{
  @Test
  public void testMulti()
  {
    String type = "hi";
    IBoth both = new IBoth() {
      @Override
      public String getType()
      {
        return type;
      }
    };
    String theType = both.getType();
  }
}

@@ -652,22 +652,102 @@
 ort 
-org.junit.Test
+manifold.util.ReflectUtil;%0Aimport org.junit.Test;%0A%0Aimport static org.junit.Assert.assertEquals
 ;%0A%0Ap
@@ -832,16 +832,257 @@
 = %22hi%22;%0A
+    IBoth both = () -%3E type;%0A%0A    assertEquals( String.class, ReflectUtil.method( both, %22getType%22 ).getMethod().getReturnType() );%0A    assertEquals( %22hi%22, both.getType() );%0A%0A// should produce compile error: MSG_NASTY_INFERRED_PROPERTY_REF%0A//
     IBot
@@ -1104,16 +1104,18 @@
 oth() %7B%0A
+//
       @O
@@ -1122,16 +1122,18 @@
 verride%0A
+//
       pu
@@ -1158,16 +1158,18 @@
 e()%0A
+//
       %7B%0A
     
@@ -1160,24 +1160,26 @@
 )%0A//      %7B%0A
+//
         retu
@@ -1191,16 +1191,18 @@
 pe;%0A
+//
       %7D%0A
     
@@ -1201,52 +1201,17 @@
   %7D%0A
+//
     %7D;%0A
-    String theType = both.getType();%0A
   %7D%0A

fix test