Skip to content

Package: TestDomain

TestDomain

nameinstructionbranchcomplexitylinemethod
TestDomain()
M: 26 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 3 C: 0
0%
M: 1 C: 0
0%
TestDomain(String)
M: 29 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 5 C: 0
0%
M: 1 C: 0
0%
getActions()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
getGroupable()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
getName()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
setActions(Set)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
setGroupable(boolean)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
setName(String)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%

Coverage

1: /*******************************************************************************
2: * Copyright (c) 2016, 2020 Eurotech and/or its affiliates and others
3: *
4: * All rights reserved. This program and the accompanying materials
5: * are made available under the terms of the Eclipse Public License v1.0
6: * which accompanies this distribution, and is available at
7: * http://www.eclipse.org/legal/epl-v10.html
8: *
9: * Contributors:
10: * Eurotech - initial API and implementation
11: *******************************************************************************/
12: package org.eclipse.kapua.qa.common;
13:
14: import com.google.common.collect.Lists;
15: import org.eclipse.kapua.commons.model.AbstractKapuaEntity;
16: import org.eclipse.kapua.model.domain.Actions;
17: import org.eclipse.kapua.service.authorization.domain.Domain;
18:
19: import java.util.HashSet;
20: import java.util.Set;
21:
22: /**
23: * Test domain.<br>
24: *
25: * @since 1.0
26: */
27: public class TestDomain extends AbstractKapuaEntity implements Domain, org.eclipse.kapua.model.domain.Domain {
28:
29: private static final long serialVersionUID = 3782336558657796495L;
30:
31: private String name = "test";
32: private Set<Actions> actions = new HashSet<>(Lists.newArrayList(Actions.read, Actions.delete, Actions.write));
33: private boolean groupable;
34:
35: public TestDomain() {}
36:
37: public TestDomain(String name) {
38: this.name = name;
39: }
40:
41: @Override
42: public void setName(String name) {
43: this.name = name;
44: }
45:
46: @Override
47: public String getName() {
48: return name;
49: }
50:
51: @Override
52: public void setActions(Set<Actions> actions) {
53: this.actions = actions;
54: }
55:
56: @Override
57: public Set<Actions> getActions() {
58: return actions;
59: }
60:
61: @Override
62: public boolean getGroupable() {
63: return groupable;
64: }
65:
66: @Override
67: public void setGroupable(boolean groupable) {
68: this.groupable = groupable;
69: }
70: }