Skip to content

ListBuilder proxy objects don't override "Set" method #35

Closed
@Quantumplation

Description

@Quantumplation

The "Set" method is a convenient way to make changes to your builder objects without having to write a different method for every field on your object. However, when you are working with the ListBuilder proxy objects (the dynamic types which derive from existing builders), they don't override the Set method. This means that the following code:

    var customers = 
        CustomerBuilder.CreateListOfSize(10)
            .All().Set(c => c.FirstName, "test");

Is not working as expected, and instead has to be

    var customers = 
        CustomerBuilder.CreateListOfSize(10)
            .All().With(cb => cb.Set(c => c.FirstName, "test"));

Any way we can get the proxy generation to override the Set method as well?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions