Skip to content

Commit c36a21c

Browse files
authored
fixed tests not to skip (#4)
Signed-off-by: Alexander Piskun <bigcat88@icloud.com>
1 parent 551298c commit c36a21c

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

tests/apps_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def test_list_apps(nc):
2121
assert APP_NAME in apps
2222

2323

24-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
24+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
2525
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
2626
def test_enable_disable_app(nc):
2727
assert nc.apps.is_installed(APP_NAME)

tests/groups_test.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
TEST_GROUP_NAME = "test_coverage_group"
88

99

10-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
10+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
1111
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
1212
def test_create_delete_group(nc):
1313
try:
@@ -22,7 +22,7 @@ def test_create_delete_group(nc):
2222
nc.users_groups.delete(TEST_GROUP_NAME)
2323

2424

25-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
25+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
2626
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
2727
def test_list_group(nc):
2828
try:
@@ -46,7 +46,7 @@ def test_list_group(nc):
4646
nc.users_groups.delete(TEST_GROUP_NAME + "2")
4747

4848

49-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
49+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
5050
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
5151
def test_group_members_promote_demote(nc):
5252
try:

tests/users_test.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def test_get_user_404(nc):
2121
nc.users.get("non existing user")
2222

2323

24-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
24+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
2525
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
2626
def test_create_user(nc):
2727
try:
@@ -33,7 +33,7 @@ def test_create_user(nc):
3333
nc.users.create(TEST_USER_NAME, password=TEST_USER_PASSWORD)
3434

3535

36-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
36+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
3737
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
3838
def test_delete_user(nc):
3939
try:
@@ -45,7 +45,7 @@ def test_delete_user(nc):
4545
nc.users.delete(TEST_USER_NAME)
4646

4747

48-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
48+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
4949
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
5050
def test_list_users(nc):
5151
try:
@@ -62,7 +62,7 @@ def test_list_users(nc):
6262
nc.users.delete(TEST_USER_NAME)
6363

6464

65-
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1], Nextcloud), reason="Not available for NextcloudApp.")
65+
@pytest.mark.skipif(not isinstance(NC_TO_TEST[:1][0], Nextcloud), reason="Not available for NextcloudApp.")
6666
@pytest.mark.parametrize("nc", NC_TO_TEST[:1])
6767
def test_enable_disable_user(nc):
6868
try:

0 commit comments

Comments
 (0)