<?xml version="1.0" encoding="us-ascii"?><InstanceReport xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><Version>2.4.0.8</Version><ReportLongName>000090 - Disclosure - 7. Commitments and Contingencies</ReportLongName><DisplayLabelColumn>true</DisplayLabelColumn><ShowElementNames>false</ShowElementNames><RoundingOption /><HasEmbeddedReports>false</HasEmbeddedReports><Columns><Column FlagID="0"><Id>1</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><CurrencyCode /><FootnoteIndexer /><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><MCU><KeyName /><CurrencySymbol /><contextRef><ContextID>D130101_130630</ContextID><EntitySchema>http://www.sec.gov/CIK</EntitySchema><EntityValue>0001351901</EntityValue><PeriodDisplayName /><PeriodType>duration</PeriodType><PeriodStartDate>2013-01-01T00:00:00</PeriodStartDate><PeriodEndDate>2013-06-30T00:00:00</PeriodEndDate><Segments /><Scenarios /></contextRef><UPS /><CurrencyCode /><OriginalCurrencyCode /></MCU><CurrencySymbol /><Labels><Label Key="CalendarSupplement" Id="0" Label="6 Months Ended" /><Label Key="Calendar" Id="1" Label="Jun. 30, 2013" /></Labels></Column></Columns><Rows><Row FlagID="0"><Id>1</Id><IsAbstractGroupTitle>true</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><Level>1</Level><ElementName>us-gaap_DisclosureTextBlockAbstract</ElementName><ElementPrefix>us-gaap_</ElementPrefix><IsBaseElement>true</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText /><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>xbrli:stringItemType</ElementDataType><SimpleDataType>string</SimpleDataType><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>Notes</Label></Row><Row FlagID="0"><Id>2</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelSeparator>

</LabelSeparator><Level>2</Level><ElementName>us-gaap_CommitmentsAndContingenciesDisclosureTextBlock</ElementName><ElementPrefix>us-gaap_</ElementPrefix><IsBaseElement>true</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsCalendarTitle>false</IsCalendarTitle><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><FootnoteIndexer /><Cells><Cell FlagID="0" ContextID="D130101_130630" UnitID=""><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText>&lt;!--egx--&gt;&lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;&lt;b&gt;7. Commitments and Contingencies&lt;/b&gt;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;&amp;nbsp;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%'&gt;&lt;b&gt;&lt;u&gt;&lt;font style='line-height:115%'&gt;Allied Health Care Services&lt;/font&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%'&gt;&lt;font style='line-height:115%'&gt;As previously disclosed in the Partnership&amp;#146;s Annual Report on Form 10-K for the year ended December 31, 2012, management had fully impaired all equipment and reserved for all accounts receivable related to the lease to Allied Health Care Services, Inc. (&amp;#147;Allied&amp;#148;), due to the bankruptcy of Allied and the criminal conviction of its founder for fraud.&amp;nbsp; During 2013, the fully reserved accounts receivable was written off. There have been no material changes in the status of Allied&amp;#146;s bankruptcy or in the likelihood of recovering available assets since the date of the Partnership&amp;#146;s annual report. The deadline for the bankruptcy trustee to pursue adversary claims against certain creditors has expired, including extensions. The bankruptcy trustee cannot seek to claim the Partnership's payments received from Allied, therefore the Partnership has no exposure to such potential claims. Commonwealth continues to pursue all of our rights against both Allied and Mr. Schwartz to recover any available assets to the greatest extent possible.&lt;/font&gt;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;&lt;b&gt;&lt;u&gt;Regulatory Activities&lt;/u&gt;&lt;/b&gt;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;&amp;nbsp;&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;In August 2012 Commonwealth Capital Securities Corp (&amp;#147;CCSC&amp;#148;) and Commonwealth Capital Corp., the parent of CCSC and the General Partner, received communication from the staff of the U.S. Securities and Exchange Commission with respect to the interpretation and application of control person with regards to the limits on reimbursement of certain expenses.&amp;#160; The staff had also indicated on their communication that they are not suggesting any egregious intent or violation. As a result of ongoing correspondence and conversation, CCC volunteered to and provided clarifying changes that have been made in disclosures in ongoing registration documents used by funds. While management believes that resolution of these issues with this agency will not result in any adverse financial impact on the Funds, we are involved in discussions with staff members to finalize resolution, but no assurance can be provided until resolution comes to conclusion.&amp;#160; On May 3, 2013, the FINRA Department of Enforcement filed a complaint naming CCSC and the owner of the firm, Kimberly Springsteen-Abbott, as respondents.&amp;#160; The complaint alleges that Ms. Springsteen-Abbott approved misallocation of certain expenses to the funds.&amp;#160; Management believes that the expenses at issue include amounts that were proper and were properly allocated to funds, and expenses that had been allocated in error but were previously adjusted and repaid to the affected funds when they were identified.&amp;#160;&amp;#160;&amp;#160;&amp;#160; CCSC and Ms. Springsteen-Abbott deny the allegations and intend to vigorously defend the proceeding.&amp;#160; Since the FINRA exam, CCC has instituted additional procedures to avoid any such errors in the future.&amp;#160; Management believes that resolution of these issues will not result in any adverse financial impact on the Funds, but no assurance can be provided until resolution comes to conclusion.&lt;/p&gt; &lt;p style='margin-top:0in;margin-right:0in;margin-bottom:10.0pt;margin-left:0in;line-height:115%;margin-bottom:0in;margin-bottom:.0001pt;line-height:normal'&gt;&amp;nbsp;&lt;/p&gt;</NonNumbericText><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat></Cell></Cells><ElementDataType>nonnum:textBlockItemType</ElementDataType><SimpleDataType>na</SimpleDataType><ElementDefenition>The entire disclosure for commitments and contingencies.</ElementDefenition><ElementReferences>Reference 1: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 210

 -SubTopic 10

 -Section S99

 -Paragraph 1

 -Subparagraph (SX 210.5-02.25)

 -URI http://asc.fasb.org/extlink&amp;oid=6877327&amp;loc=d3e13212-122682



Reference 2: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 825

 -SubTopic 20

 -Section 50

 -Paragraph 1

 -URI http://asc.fasb.org/extlink&amp;oid=6449706&amp;loc=d3e16207-108621



Reference 3: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 460

 -SubTopic 10

 -Section 50

 -Paragraph 8

 -URI http://asc.fasb.org/extlink&amp;oid=6398077&amp;loc=d3e12565-110249



Reference 4: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 450

 -SubTopic 20

 -Section 50

 -Paragraph 4

 -URI http://asc.fasb.org/extlink&amp;oid=25496072&amp;loc=d3e14435-108349



Reference 5: http://www.xbrl.org/2003/role/presentationRef

 -Publisher FASB

 -Name Accounting Standards Codification

 -Topic 440

 -SubTopic 10

 -Section 50

 -Paragraph 2

 -URI http://asc.fasb.org/extlink&amp;oid=6394976&amp;loc=d3e25287-109308



</ElementReferences><IsTotalLabel>false</IsTotalLabel><UnitID>0</UnitID><Label>7. Commitments and Contingencies</Label></Row></Rows><Footnotes /><IsEquityReport>false</IsEquityReport><ReportName>7. Commitments and Contingencies</ReportName><MonetaryRoundingLevel>UnKnown</MonetaryRoundingLevel><SharesRoundingLevel>UnKnown</SharesRoundingLevel><PerShareRoundingLevel>UnKnown</PerShareRoundingLevel><ExchangeRateRoundingLevel>UnKnown</ExchangeRateRoundingLevel><HasCustomUnits>true</HasCustomUnits><IsEmbedReport>false</IsEmbedReport><IsMultiCurrency>false</IsMultiCurrency><ReportType>Sheet</ReportType><RoleURI>http://www.ccclease.com/20130630/role/idr_Disclosure7CommitmentsAndContingencies</RoleURI><NumberOfCols>1</NumberOfCols><NumberOfRows>2</NumberOfRows></InstanceReport>
