2 writes to Id
Microsoft.Build (2)
BuildCheck\API\CheckRule.cs (2)
30
Id
= id;
53
Id
= id;
35 references to Id
Microsoft.Build (28)
BuildCheck\API\BuildCheckResult.cs (2)
41
public string Code => CheckRule.
Id
;
57
? $"https://aka.ms/buildcheck/codes#{CheckRule.
Id
} - {string.Format(CheckRule.MessageFormat, MessageArgs)}"
BuildCheck\Checks\PropertiesUsageCheck.cs (7)
49
var config = configurationContext.CheckConfig.FirstOrDefault(c => c.RuleId == _usedBeforeInitializedRule.
Id
)
55
config = configurationContext.CheckConfig.FirstOrDefault(c => c.RuleId == _unusedPropertyRule.
Id
)
61
config = configurationContext.CheckConfig.FirstOrDefault(c => c.RuleId == _usedBeforeInitializedRule.
Id
)
73
GetAllowUninitPropsInConditionsConfig(customConfigurationData, _usedBeforeInitializedRule.
Id
);
75
GetAllowUninitPropsInConditionsConfig(customConfigurationData, _initializedAfterUsedRule.
Id
);
83
$"[{_usedBeforeInitializedRule.
Id
}] and [{_initializedAfterUsedRule.
Id
}] are not allowed to have differing configuration value for [{_allowUninitPropsInConditionsKey}]");
BuildCheck\Infrastructure\BuildCheckManagerProvider.cs (14)
148
new BuiltInCheckFactory([SharedOutputPathCheck.SupportedRule.
Id
], SharedOutputPathCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<SharedOutputPathCheck>),
149
new BuiltInCheckFactory([PreferProjectReferenceCheck.SupportedRule.
Id
], PreferProjectReferenceCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<PreferProjectReferenceCheck>),
150
new BuiltInCheckFactory([CopyAlwaysCheck.SupportedRule.
Id
], CopyAlwaysCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<CopyAlwaysCheck>),
151
new BuiltInCheckFactory([DoubleWritesCheck.SupportedRule.
Id
], DoubleWritesCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<DoubleWritesCheck>),
152
new BuiltInCheckFactory([ExecCliBuildCheck.SupportedRule.
Id
], ExecCliBuildCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<ExecCliBuildCheck>),
153
new BuiltInCheckFactory([NoEnvironmentVariablePropertyCheck.SupportedRule.
Id
], NoEnvironmentVariablePropertyCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<NoEnvironmentVariablePropertyCheck>),
154
new BuiltInCheckFactory([EmbeddedResourceCheck.SupportedRule.
Id
], EmbeddedResourceCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<EmbeddedResourceCheck>),
155
new BuiltInCheckFactory([TargetFrameworkConfusionCheck.SupportedRule.
Id
], TargetFrameworkConfusionCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<TargetFrameworkConfusionCheck>),
156
new BuiltInCheckFactory([TargetFrameworkUnexpectedCheck.SupportedRule.
Id
], TargetFrameworkUnexpectedCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<TargetFrameworkUnexpectedCheck>),
157
new BuiltInCheckFactory([UntrustedLocationCheck.SupportedRule.
Id
], UntrustedLocationCheck.SupportedRule.DefaultConfiguration.IsEnabled ?? false, Construct<UntrustedLocationCheck>),
162
new BuiltInCheckFactory(PropertiesUsageCheck.SupportedRulesList.Select(r => r.
Id
).ToArray(),
219
instance.SupportedRules.Select(r => r.
Id
).ToArray(),
286
!check.SupportedRules.Select(r => r.
Id
)
291
$"The check '{check.FriendlyName}' exposes rules '{check.SupportedRules.Select(r => r.
Id
).ToCsvString()}', but different rules were declared during registration: '{checkFactoryContext.RuleIds.ToCsvString()}'");
BuildCheck\Infrastructure\BuildEventsProcessor.cs (2)
254
$"The check '{checkWrapper.Check.FriendlyName}' reported a result for a rule '{result.CheckRule.
Id
}' that it does not support.");
261
r.RuleId.Equals(result.CheckRule.
Id
, StringComparison.CurrentCultureIgnoreCase));
BuildCheck\Infrastructure\CheckWrapper.cs (1)
57
ruleId: checkRule.
Id
,
BuildCheck\Infrastructure\ConfigurationProvider.cs (2)
134
check.SupportedRules[idx].
Id
,
258
=> GetMergedConfiguration(projectFullPath, checkRule.
Id
, checkRule.DefaultConfiguration);
Microsoft.Build.BuildCheck.UnitTests (7)
DoubleWritesAnalyzer_Tests.cs (2)
53
_registrationContext.Results[0].CheckRule.
Id
.ShouldBe("BC0102");
74
_registrationContext.Results.ForEach(result => result.CheckRule.
Id
.ShouldBe("BC0102"));
ExecCliBuildCheck_Tests.cs (1)
77
_registrationContext.Results[0].CheckRule.
Id
.ShouldBe("BC0302");
SharedOutputPathCheck_Tests.cs (3)
89
_registrationContext.Results[0].CheckRule.
Id
.ShouldBe("BC0101");
90
_registrationContext.Results[1].CheckRule.
Id
.ShouldBe("BC0101");
134
result.CheckRule.
Id
.ShouldBe("BC0101");
TaskInvocationAnalysisDataTests.cs (1)
67
new ([TestCheck.SupportedRule.
Id
], true, () => s_testCheck = new TestCheck()),