Skip to content
Snippets Groups Projects
Commit ce01ec4d authored by Diego Giovane Pasqualin's avatar Diego Giovane Pasqualin
Browse files

Merge branch 'issue/27' into 'development'


Issue #27: Integra teste de criar usuario e o de retorno

Signed-off-by: default avatarFelipe Shi Iu Wu <felipeshiwu@gmail.com>

See merge request !27
parents 0510e0eb 25b478a9
No related branches found
No related tags found
2 merge requests!51Merge development to master,!27Issue #27: Integra teste de criar usuario e o de retorno
Pipeline #
......@@ -41,11 +41,13 @@ testDebian:
- regular
- debian
script:
- apt-get update && apt-get install -y git jq
- apt-get update && apt-get install -y git jq faketime expect
- git clone https://github.com/sstephenson/bats.git
- cd bats
- ./install.sh /usr
- cd ../test
- ./create_users.sh
- last -F
- ./returnTest.bats
dependencies:
- compile
......@@ -56,8 +58,10 @@ testUbuntu:
- ubuntu
- regular
script:
- apt-get update && apt-get install -y bats jq
- apt-get update && apt-get install -y bats jq faketime expect
- cd test
- ./create_users.sh
- last -F
- ./returnTest.bats
dependencies:
- compile
......@@ -68,8 +72,13 @@ testOpensuse:
- opensuse
script:
- zypper -n update
- zypper -n install bats && zypper -n install jq
- zypper -n install bats jq libfaketime expect
- touch /var/log/wtmp
- chown root.tty /var/log/wtmp
- chmod 664 /var/log/wtmp
- cd test
- ./create_users.sh
- last -F
- ./returnTest.bats
dependencies:
- compile
#!/usr/bin/env bats
function amount_users() {
expected_number_of_users=3
obj=$(cat export.json | jq -r '.data.amount_users')
[[ "$obj" -eq "$obj" ]] && [[ "$obj" != "null" ]]
[[ "$obj" -eq "$expected_number_of_users" ]] && [[ "$obj" != "null" ]]
}
function mac_address() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment