@@ -24,19 +24,17 @@ def test_graphql_get_file_analysis_invalid_argument(self):
2424 :return:
2525 """
2626 with self .assertRaises (ValueError ):
27- graphql_get_file_analysis (None , "bla" , 1 )
27+ graphql_get_file_analysis (None , 1 )
2828 with self .assertRaises (ValueError ):
29- graphql_get_file_analysis ("blo" , None , 1 )
30- with self .assertRaises (ValueError ):
31- graphql_get_file_analysis ("blo" , "bli" , None )
29+ graphql_get_file_analysis ("blo" , None )
3230
3331 @patch ('codiga.graphql.file_analysis.do_graphql_query' )
3432 def test_graphql_get_file_analysis_check_call (self , do_graphql_query_mock ):
3533 """
3634 Check that we call the right method when arguments are valid
3735 :return:
3836 """
39- graphql_get_file_analysis ("accesskey" , "secret_key " , 1 )
37+ graphql_get_file_analysis ("api_token " , 1 )
4038 do_graphql_query_mock .assert_called ()
4139
4240 @patch ('codiga.graphql.file_analysis.do_graphql_query' )
@@ -45,10 +43,10 @@ def test_graphql_create_file_analysis_check_call(self, do_graphql_query_mock):
4543 Check that we call the right method when arguments are valid
4644 :return:
4745 """
48- graphql_create_file_analysis ("accesskey" , "secret_key " , "filename" , "language" , "content" , 1 )
46+ graphql_create_file_analysis ("api_token " , "filename" , "language" , "content" , 1 )
4947 query = {'query' : '\n mutation{\n createFileAnalysis (\n language: language,\n code: "content",\n filename: "filename"\n projectId: 1\n )\n }\n ' }
50- do_graphql_query_mock .assert_called_with ("accesskey" , "secret_key " , query )
48+ do_graphql_query_mock .assert_called_with ("api_token " , query )
5149
52- graphql_create_file_analysis ("accesskey" , "secret_key " , "filename" , "language" , "content" , None )
50+ graphql_create_file_analysis ("api_token " , "filename" , "language" , "content" , None )
5351 query = {'query' : '\n mutation{\n createFileAnalysis (\n language: language,\n code: "content",\n filename: "filename"\n projectId: null\n )\n }\n ' }
54- do_graphql_query_mock .assert_called_with ("accesskey" , "secret_key " , query )
52+ do_graphql_query_mock .assert_called_with ("api_token " , query )
0 commit comments