Frequently Asked QuestionsWhat is the SP-Lint+? Note: The code generation options are currently
under development and while they are included in this release they are
expected to be more robust shortly. P = Passed validation R = Reserved attributes D = Deployed components or resources W = Warning, not following a recommendation or convention Can I exclude particular validation tests? Yes- you can identify validations which you don't want to report and identify their id's as a collection in the SP-Lint+ environment.xml file. What does a typical validation report look like? The following output demonstrates an SP-Lint+ 'run' when all validation categories are reported in a verbose text mode. Starting validation processing... Begin feature processing: C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\feature.xml Passed: FID007 Determine if the value of the ActiveOnDefault attribute is valid. Passed: FID008 Determine if the value of the AlwaysForceInstall attribute is valid. Passed: FID009 Determine if the value of the AutoActivateInCentralAdmin attribute is valid. Passed: FID001 Determine if the value of the Hidden attribute is valid. Passed: FID002 Determine if the value of the feature id is defined and valid. Failed: FID003 Determine if the image associated with the ImageUrl attribute has been deployed. Result: Feature ImageUrl is not deployed: Passed: FID004 Determine if the image associated with the ImageUrl for the feature has been found in the source. Passed: FID005 Determine if the Scope attribute associated with a feature is valid. Passed: FID014 Determine if the assembly identified by the ReceiverAssembly attribute has been deployed to the GAC. Passed: FID012 Determine if the PublicKeyToken component of the ReceiverAssembly attribute is valid. Passed: FID007 Determine if the value of the ActiveOnDefault attribute is valid. Passed: FID006 Determine if the receiver class is a valid source target in the feature. Passed: FID010 Determine if the DefaultResourceFile is a valid source target of the feature. Failed: FID011 Determine if the DefaultResourceFile associated with the feature has been deployed. Result: The DefaultResourceFile for the feature is not deployed: Begin element processing: C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\elements.xml Start CustomAction: SiteActionsToolbar Passed: CAID004 Determine if the ContentTypeId attribute is valid. Passed: CAID003 Determine if the ControlAssembly attribute for the element is valid. Passed: CAID001 Determine if the assembly identified by the ControlAssembly attribute has been deployed to the GAC. Passed: CAID008 Determine if the Id attribute is valid. Passed: CAID006 Determine if the ControlClass and ControlSrc attributes are valid. Passed: CAID009 Determine if the GroupId attribute is valid. Warning : CAID008 Determine if the Id attribute is valid. Result: The Id attribute is typically defined as a GUID. Passed: CAID016 Determine if the ImageUrl source is valid. Failed: CAID017 Determine if the resource specified by the ImageUrl is deployed. Result: The image specified by the ImageUrl attribute for this resource is not deployed. Passed: CAID007 Determine if the Location attribute is valid. Passed: CAID011 Determine if the RegistrationId is valid. Passed: CAID005 Determine if the RegistrationType attribute is valid. Passed: CAID016 Determine if RequiresSiteAdministrator is valid. Passed: CAID010 Determine if the Rights attribute is valid. Passed: CAID013 Determine if the Sequence attribute is valid. Passed: CAID015 Determine if the ShowInLists attribute is valid. Passed: CAID014 Determine if ShowInreadOnlyContentTypes is valid. Passed: CAID012 Determine if the ShowInSealedContentTypes attribute is valid. Passed: CAID002 Determine if the CustomAction specifies a Title as required. Start UrlActtion: Passed: CAURLID001 The Url attribute is required. Determine if it exists. End UrlAction End CustomAction Completed element processing. Completed feature processing. Begin feature processing: C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\feature.xml Passed: FID007 Determine if the value of the ActiveOnDefault attribute is valid. Passed: FID008 Determine if the value of the AlwaysForceInstall attribute is valid. Passed: FID009 Determine if the value of the AutoActivateInCentralAdmin attribute is valid. Passed: FID001 Determine if the value of the Hidden attribute is valid. Passed: FID002 Determine if the value of the feature id is defined and valid. Failed: FID003 Determine if the image associated with the ImageUrl attribute has been deployed. Result: Feature ImageUrl is not deployed: Passed: FID004 Determine if the image associated with the ImageUrl for the feature has been found in the source. Passed: FID005 Determine if the Scope attribute associated with a feature is valid. Passed: FID014 Determine if the assembly identified by the ReceiverAssembly attribute has been deployed to the GAC. Passed: FID012 Determine if the PublicKeyToken component of the ReceiverAssembly attribute is valid. Passed: FID007 Determine if the value of the ActiveOnDefault attribute is valid. Passed: FID006 Determine if the receiver class is a valid source target in the feature. Passed: FID010 Determine if the DefaultResourceFile is a valid source target of the feature. Failed: FID011 Determine if the DefaultResourceFile associated with the feature has been deployed. Result: The DefaultResourceFile for the feature is not deployed: Begin element processing: C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\elements.xml Start CustomAction: SiteActionsToolbar Passed: CAID004 Determine if the ContentTypeId attribute is valid. Passed: CAID003 Determine if the ControlAssembly attribute for the element is valid. Passed: CAID001 Determine if the assembly identified by the ControlAssembly attribute has been deployed to the GAC. Passed: CAID008 Determine if the Id attribute is valid. Passed: CAID006 Determine if the ControlClass and ControlSrc attributes are valid. Passed: CAID009 Determine if the GroupId attribute is valid. Warning: CAID008 Determine if the Id attribute is valid. Result: The Id attribute is typically defined as a GUID. Passed: CAID016 Determine if the ImageUrl source is valid. Failed: CAID017 Determine if the resource specified by the ImageUrl is deployed. Result: The image specified by the ImageUrl attribute for this resource is not deployed. Passed: CAID007 Determine if the Location attribute is valid. Passed: CAID011 Determine if the RegistrationId is valid. Passed: CAID005 Determine if the RegistrationType attribute is valid. Passed: CAID016 Determine if RequiresSiteAdministrator is valid. Passed: CAID010 Determine if the Rights attribute is valid. Passed: CAID013 Determine if the Sequence attribute is valid. Passed: CAID015 Determine if the ShowInLists attribute is valid. Passed: CAID014 Determine if ShowInreadOnlyContentTypes is valid. Passed: CAID012 Determine if the ShowInSealedContentTypes attribute is valid. Passed: CAID002 Determine if the CustomAction specifies a Title as required. Start UrlActtion: Passed: CAURLID001 The Url attribute is required. Determine if it exists. End UrlAction End CustomAction Completed element processing. Completed feature processing. Validation Summary - 60 Passed, 1 Warnings, 0 Errors, 0 Obsolete, 0 Reserved, 0 Ignored, 2 Deployment How does a report appear when formatted in xml? The following output demonstrates an SP-Lint+ 'run' when all validation categories are reported as an XML file. <?xml version="1.0" encoding="utf-8"?> <Feature filespec="C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\feature.xml"> <Validation Status="failed" Validation="Determine if the value of the ActiveOnDefault attribute is valid." ValidationId="FID007" /> <Validation Status="failed" Validation="Determine if the value of the AlwaysForceInstall attribute is valid." ValidationId="FID008" /> <Validation Status="passed" Validation="Determine if the value of the Hidden attribute is valid." ValidationId="FID001" /> <Validation Status="passed" Validation="Determine if the value of the feature id is defined and valid." ValidationId="FID002" /> <Validation Status="failed" Validation="Determine if the image associated with the ImageUrl attribute has been deployed." ValidationId="FID003" /> <Validation Status="passed" Validation="Determine if the image associated with the ImageUrl for the feature has been found in the source." ValidationId="FID004" /> <Validation Status="passed" Validation="Determine if the Scope attribute associated with a feature is valid." ValidationId="FID005" /> <Validation Status="failed" Validation="Determine if the assembly identified by the ReceiverAssembly attribute has been deployed to the GAC." ValidationId="FID014" /> <Validation Status="passed" Validation="Determine if the PublicKeyToken component of the ReceiverAssembly attribute is valid." ValidationId="FID012" /> <Validation Status="failed" Validation="Determine if the value of the ActiveOnDefault attribute is valid." ValidationId="FID007" /> <Validation Status="passed" Validation="Determine if the receiver class is a valid source target in the feature." ValidationId="FID006" /> <Validation Status="failed" Validation="Determine if the DefaultResourceFile is a valid source target of the feature." ValidationId="FID010" /> <Validation Status="failed" Validation="Determine if the DefaultResourceFile associated with the feature has been deployed." ValidationId="FID011" /> <Element filespec="C:\Projects\Features\FirstFeature\TEMPLATE\FEATURES\Simple\elements.xml"> <CustomAction Identifier="SiteActionsToolbar"> <Validation Status="passed" Validation="Determine if the ContentTypeId attribute is valid." ValidationId="CAID004" /> <Validation Status="passed" Validation="Determine if the ControlAssembly attribute for the element is valid." ValidationId="CAID003" /> <Validation Status="passed" Validation="Determine if the assembly identified by the ControlAssembly attribute has been deployed to the GAC." ValidationId="CAID001" /> <Validation Status="passed" Validation="undefined" ValidationId="undefined" /> <Validation Status="passed" Validation="Determine if the ControlClass and ControlSrc attributes are valid." ValidationId="CAID006" /> <Validation Status="passed" Validation="Determine if the GroupId attribute is valid." ValidationId="CAID009" /> <Validation Status="passed" Validation="Determine if the Id attribute is valid." ValidationId="CAID008" /> <Validation Status="passed" Validation="Determine if the Location attribute is valid." ValidationId="CAID007" /> <Validation Status="passed" Validation="Determine if the RegistrationType attribute is valid." ValidationId="CAID005" /> <Validation Status="passed" Validation="Determine if the CustomAction specifies a Title as required." ValidationId="CAID002" /> <UrlAction Identifier=""> <Validation Status="passed" Validation="The Url attribute is required. Determine if it exists." ValidationId="CAURLID001" /> </UrlAction> </CustomAction> </Element> </Feature> I want an example of the kinds of checking that SP-Lint+ can perform! Ok, sure, here's some validation that the utility can perform. If you are creating a feature that contains a custom action, you will need to include a ControlAssembly attribute. Any well formed attribute of this type must contain four components. The name, version, culture and public key token. (as follows) ControlAssembly="FirstFeature, Version=1.0.0.0, Culture=neutral, PublicKeyToken=b28a02315c3357c4" SSPV performs a number of tests on this attribute, including: - check to make sure that the four attribute components are defined - validate that the version is only numeric and properly formatted - verify that a class exists with the assembly name - report if the assembly exists in the GAC - compare the public key token to that which is registered for this GAC'd assembly What is the enviroment.xml file and what is it's purpose? The environment.xml file contains paths to the .NET strong name and the global assembly cache utilities. These utilities enable SP-Lint+ to perform some its validations. They are typically in the path of the visual studio or MSBuild environment where you execute SP-Lint+, but the explicit paths can be identified here. Also the environment file can contain a collection of SP-Lint+ validator identifies that you want to ignore. <Environment snexe="\sn.exe" gacutil="\Program Files\Microsoft SDKs\Windows\v6.0A\Bin\gacutil.exe" > <IgnoreFailedValidators> <IgnoreFailedValidatorId>FID009</IgnoreFailedValidatorId> </IgnoreFailedValidators> </Environment> How large is the SP-Lint+ utility and how much time does it take to analyze a project? The SP-Lint+ utility is just 400K in size and takes less than a second to run on a typical developer machine. What does SP-Lint+ cost? SP-Lint+ is a free downloadable trial. The product is in development and this Beta designator is expected to remain for the foreseeable future. Have you seen the economy lately? Hardworking SharePoint developers can certainly use a break in stocking their tool belts. How can I report issues that I find with SP-Lint+? There are a number of ways that you can reach the SP-Lint+ developers, send an email or post to the forum. How often will SP-Lint+ be updated? It is expected that a new (hopefully improved) version of SP-Lint+ will be available for download every 45 days. |


