Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • T tdt4242-base
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Andreas Rimolsrønning
  • tdt4242-base
  • Merge requests
  • !10

Fix the UserSerializer class

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Einar Uvsløkk requested to merge fix/user-serializer into master Mar 14, 2021
  • Overview 0
  • Commits 1
  • Pipelines 1
  • Changes 3

During black box testing of FR5 (View Workout) a bug in the class-level validation on the UserSerializer class was discovered. When accepting a coach offer, user validation would fail, complaining about the password being None.

The changes made to the initial implementation is know mostly reverted. Class-level validation is removed in favour of field-level validation for the password field. The implementation of the password validation, however, remains the same.

Additionally, default values for related required fields are know declared using the extra_kwargs attribute.

Unit tests for the UserSerializer class is also updated, to reflect the changes.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: fix/user-serializer