Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
Rights Engine
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Polaris
Rights Engine
Commits
ef4ae00a
Commit
ef4ae00a
authored
3 weeks ago
by
Lennard Strohmeyer
Browse files
Options
Downloads
Patches
Plain Diff
#155
: fixed data disclosure tests for environments where no mongodb is...
#155
: fixed data disclosure tests for environments where no mongodb is available or the LRS is empty
parent
53ef3e7f
No related branches found
No related tags found
1 merge request
!1
#155: fixed data disclosure tests for environments where no mongodb is...
Pipeline
#1653595
failed
3 weeks ago
Stage: test
Stage: build
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/data_disclosure/tests/tests_data_disclosure.py
+7
-0
7 additions, 0 deletions
src/data_disclosure/tests/tests_data_disclosure.py
with
7 additions
and
0 deletions
src/data_disclosure/tests/tests_data_disclosure.py
+
7
−
0
View file @
ef4ae00a
import
json
import
os
from
io
import
StringIO
from
unittest.mock
import
patch
from
django.conf
import
settings
from
django.core.files.base
import
ContentFile
...
...
@@ -14,6 +15,8 @@ from providers.models import ProviderAuthorization, Provider, ProviderVerbGroup,
from
users.models
import
CustomUser
from
data_disclosure.models
import
DataDisclosure
from
data_disclosure.tasks
import
DataDisclosureProcessor
class
TestsDataDisclosure
(
BaseTestCase
):
...
...
@@ -35,6 +38,10 @@ class TestsDataDisclosure(BaseTestCase):
},
]
@patch.object
(
DataDisclosureProcessor
,
'
get_xapi_statements
'
)
def
mock_get_xapi_statements
(
self
,
user_email
:
str
):
return
[]
def
setUp
(
self
):
call_command
(
'
check_and_apply_migrations
'
)
normal_user
=
CustomUser
.
objects
.
create_user
(
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment