Skip to content

Add tests chapter01 v8#67

Merged
COsborn2 merged 4 commits into
v8.0from
add-tests-chapter01-v8
Jul 23, 2019
Merged

Add tests chapter01 v8#67
COsborn2 merged 4 commits into
v8.0from
add-tests-chapter01-v8

Conversation

@COsborn2
Copy link
Copy Markdown
Contributor

@COsborn2 COsborn2 commented Jul 23, 2019

Listing 01.11A returns no output and remains "untested".

@COsborn2 COsborn2 requested a review from Keboo July 23, 2019 17:47
Comment thread src/Shared/Program.cs Outdated
Type? target = assembly.GetTypes().FirstOrDefault(type => type.FullName.Contains(input));
Type? target = assembly.GetTypes().FirstOrDefault(type =>
{
Regex reg = new Regex($"{input}\\.+");
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will create the regex for each Type declared in the assembly. It is better to move it outside of the FirstOrDefault so it is only created once.

@COsborn2 COsborn2 merged commit 04ae2d5 into v8.0 Jul 23, 2019
@COsborn2 COsborn2 deleted the add-tests-chapter01-v8 branch July 24, 2019 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants