'Scenario: Given I have a library, a course and library content xblock in a course
When I go to studio unit page for library content block
And I set Problem Type selector so that no libraries have matching content
Then I can see that "No matching content" warning is shown
When I set Problem Type selector so that there is matching content
Then I can see that warning messages are not shown'

def test_no_content_message(self):

    self.library_fixture.create_xblock(self.library_fixture.library_location, XBlockFixtureDesc('problem', 'Dropdown', data=textwrap.dedent('\n                                                                <problem>\n                                                                                <p>Dropdown</p>\n                                                                                <optionresponse><optioninput    label="Dropdown"    options="(\'1\',    \'2\')"    correct="\'2\'"></optioninput></optionresponse>\n                                                                </problem>\n                                                                ')))
    expected_text = 'There    are    no    matching    problem    types    in    the    specified    libraries.    Select    another    problem    type'
    library_container = self._get_library_xblock_wrapper(self.unit_page.xblocks[1])
    self.assertFalse(library_container.has_validation_error)
    self.assertFalse(library_container.has_validation_warning)
    library_container.edit()
    edit_modal = StudioLibraryContentEditor(self.browser, library_container.locator)
    self.assertEqual(edit_modal.capa_type, 'Any    Type')
    edit_modal.capa_type = 'Custom    Evaluated    Script'
    library_container.save_settings()
    self.assertTrue(library_container.has_validation_warning)
    self.assertIn(expected_text, library_container.validation_warning_text)
    library_container.edit()
    edit_modal = StudioLibraryContentEditor(self.browser, library_container.locator)
    self.assertEqual(edit_modal.capa_type, 'Custom    Evaluated    Script')
    edit_modal.capa_type = 'Dropdown'
    library_container.save_settings()
    self.assertFalse(library_container.has_validation_error)
    self.assertFalse(library_container.has_validation_warning)
