Add running tests
This commit is contained in:
parent
cd31ec8a20
commit
1c2adb1a92
3 changed files with 15 additions and 8 deletions
|
|
@ -3,8 +3,8 @@ on:
|
|||
push:
|
||||
|
||||
jobs:
|
||||
ansible-lint:
|
||||
name: Verify
|
||||
test:
|
||||
name: Test
|
||||
runs-on: docker
|
||||
steps:
|
||||
- uses: actions/checkout@v7
|
||||
|
|
@ -12,6 +12,6 @@ jobs:
|
|||
run: |
|
||||
apt update
|
||||
apt install -y maven
|
||||
- name: Run maven verify
|
||||
- name: Run maven verify test
|
||||
run: |
|
||||
mvn -f attribute-endpoints-provider verify
|
||||
mvn -f attribute-endpoints-provider verify test
|
||||
6
Makefile
6
Makefile
|
|
@ -1,6 +1,12 @@
|
|||
install:
|
||||
mvn -f attribute-endpoints-provider install
|
||||
|
||||
verify:
|
||||
mvn -f attribute-endpoints-provider verify
|
||||
|
||||
test:
|
||||
mvn -f attribute-endpoints-provider test
|
||||
|
||||
clean:
|
||||
mvn -f attribute-endpoints-provider clean
|
||||
|
||||
|
|
|
|||
|
|
@ -106,11 +106,12 @@ public class AttributeEndpointsResourceProviderTest {
|
|||
|
||||
@Test
|
||||
public void exportAttributeValues_doorisSlug_returnsSshKeysOfMatchingUser() {
|
||||
Response response = callAuthenticatedAs("export-dooris-ssh-keys",
|
||||
() -> new AttributeEndpointsResourceProvider(session).exportAttributeValues("dooris-ssh-keys"));
|
||||
try (Response response = callAuthenticatedAs("export-dooris-ssh-keys",
|
||||
() -> new AttributeEndpointsResourceProvider(session).exportAttributeValues("dooris-ssh-keys"))) {
|
||||
|
||||
assertEquals(200, response.getStatus());
|
||||
assertEquals(List.of("hacker-ssh-key-1", "hacker-ssh-key-2"), response.getEntity());
|
||||
assertEquals(200, response.getStatus());
|
||||
assertEquals(List.of("hacker-ssh-key-1", "hacker-ssh-key-2"), response.getEntity());
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue