* 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.
public class JU_OACodeTest {
- @Mock
- private OAFacade<Introspect> facade;
+ @Mock
+ private OAFacade<Introspect> facade;
- @Mock
- private OAFacade<Introspect> facade1;
+ @Mock
+ private OAFacade<Introspect> facade1;
- @Before
- public void setup() {
- initMocks(this);
- }
+ @Before
+ public void setup() {
+ initMocks(this);
+ }
- @Test
- public void testOACodeDefaultMethod() throws Exception {
- OACode code = new OACode(facade, "Original Description", true, "role1") {
+ @Test
+ public void testOACodeDefaultMethod() throws Exception {
+ OACode code = new OACode(facade, "Original Description", true, "role1") {
- @Override
- public void handle(AuthzTrans trans, HttpServletRequest req, HttpServletResponse resp) throws Exception {
- // Blank implementation to test abstract OACode class.
- }
- };
+ @Override
+ public void handle(AuthzTrans trans, HttpServletRequest req, HttpServletResponse resp) throws Exception {
+ // Blank implementation to test abstract OACode class.
+ }
+ };
- OACode clone = code.clone(facade1, false);
+ OACode clone = code.clone(facade1, false);
- assertNotSame(code, clone);
+ assertNotSame(code, clone);
- assertTrue(code.useJSON);
- assertFalse(clone.useJSON);
+ assertTrue(code.useJSON);
+ assertFalse(clone.useJSON);
- }
+ }
}