Skip to content
Snippets Groups Projects
Unverified Commit ae860203 authored by Peter Stanko's avatar Peter Stanko
Browse files

Project config - subdir

parent 79641561
No related branches found
No related tags found
No related merge requests found
......@@ -45,6 +45,7 @@ def update_project_test_files(course_id: str, project_id: str):
course = find_course(course_id)
project = find_project(course, project_id)
params = {
'from_dir': project.config.test_files_subdir,
'source': {
'type': 'git',
'url': project.config.test_files_source
......
......@@ -138,7 +138,7 @@ class ProjectTestFilesRefresh(Resource):
project = general.find_project(course, pid)
# authorization
permissions.PermissionsService(course=course).require.write_projects()
ProjectService(project).update_project_test_files_hash()
ProjectService(project).update_project_test_files()
return '', 204
......
......@@ -149,6 +149,7 @@ class SubmissionFileParamsSchema(Schema):
"""Submission File Params Schema
"""
source = NESTED('SubmissionFileSource', required=True)
from_dir = fields.Str(allow_none=True)
class SubmissionCreateSchema(Schema):
......
......@@ -157,7 +157,7 @@ class ProjectService:
return filters.filter_projects_from_course(course=course, user=perm_service.client)
raise ForbiddenError(uid=perm_service.client.id)
def update_project_test_files_hash(self):
def update_project_test_files(self):
""" Sends a request to Storage to update the project's test_files to the newest version.
:return: nothing
......
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