mark-gerarts / mark-gerarts/automapper-plus

QUESTION : Asserting complete mapping

Open
#86 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
PHP
Stars
562
Forks
32
PR merge metrics
No merged PRs in 30d

Description

A feature of the dotnet AutoMapper is `AssertConfigurationIsValid()` which will barf if a new property was added that was not able to be automagically mapped.

I'm trying to find a way to assert the same here. A unit test that will fail if there is a destination or source property that doesn't have an operation.

How might I go about this? Am I missing something obvious already?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing mapping configuration and the dotnet AutoMapper AssertConfigurationIsValid() behavior referenced in the issue. Determine how source and destination properties are represented, then define a failing assertion for unmapped properties and add coverage showing that complete mappings pass and missing operations fail.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.