Skip to content

Commit

Permalink
add unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
MDeLuise authored and Coduz committed Jul 12, 2022
1 parent 204ef9b commit 95a8a2d
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
5 changes: 5 additions & 0 deletions console/module/authentication/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-security-authentication-api</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*******************************************************************************
* Copyright (c) 2022 Eurotech and/or its affiliates and others
*
* This program and the accompanying materials are made
* available under the terms of the Eclipse Public License 2.0
* which is available at https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*
* Contributors:
* Eurotech - initial API and implementation
*******************************************************************************/
package org.eclipse.kapua.app.console.module.authentication.shared.model;

import org.junit.Assert;
import org.junit.Test;

public class GwtCredentialTest {

@Test
public void shouldSetCorrectPassword() {
GwtCredential gwtCredential = new GwtCredential();
String password = "foo%!`\"";
gwtCredential.setCredentialKey(password);
Assert.assertEquals(password, gwtCredential.getCredentialKey());
}

}

0 comments on commit 95a8a2d

Please sign in to comment.