@@ -76,9 +76,8 @@ httptest::with_mock_API({
76
76
if (file.exists(credentials_path )){
77
77
file.remove(credentials_path )
78
78
}
79
-
80
79
# authenticate("rtest", "asdasdasd", "https://tmc.mooc.fi")
81
- credentials_1 <- login(" a" , " b" , " c" , " d" , " tmc.mooc.fi" )
80
+ credentials_1 <- login(" a" , " b" , " c" , " d" , " tmc.mooc.fi" )
82
81
credentials_1 $ serverAddress <- " tmc.mooc.fi"
83
82
84
83
stub(get_all_organizations , " shiny::withProgress" , withProgress_mocksi )
@@ -96,30 +95,6 @@ httptest::with_mock_API({
96
95
}
97
96
})
98
97
99
- test_that(" organizations are fetched from the server" , {
100
- credentials_path <- paste(get_tmcr_directory(),
101
- " .credentials.rds" , sep = .Platform $ file.sep )
102
-
103
- if (file.exists(credentials_path )){
104
- file.remove(credentials_path )
105
- }
106
-
107
- # authenticate("rtest", "asdasdasd", "https://tmc.mooc.fi")
108
- login(" a" , " b" , " c" , " d" , " tmc.mooc.fi" )
109
-
110
- organizations <- tmcrstudioaddin :: get_all_organizations()
111
-
112
- expect_true(length(organizations $ name ) > 0 )
113
-
114
- for (organization in organizations $ name ){
115
- expect_true(is.character(organization ))
116
- }
117
-
118
- if (file.exists(credentials_path )){
119
- file.remove(credentials_path )
120
- }
121
- })
122
-
123
98
test_that(" We can get submission details" , {
124
99
token <- " asd"
125
100
url <- " https://tmc.mooc.fi/api/v8/core/submissions/1331386"
0 commit comments