def test_course_creation_for_unknown_organization_relaxed(self, store):
        """
        Tests that when ORGANIZATIONS_AUTOCREATE is True,
        creating a course-run with an unknown org slug will create an organization
        and organization-course linkage in the system.
        """
        with self.assertRaises(InvalidOrganizationException):
            get_organization_by_short_name("orgX")
        with modulestore().default_store(store):
            response = self.client.ajax_post(self.course_create_rerun_url, {
                'org': 'orgX',
                'number': 'CS101',
                'display_name': 'Course with web certs enabled',
                'run': '2015_T2'
            })
            self.assertEqual(response.status_code, 200)
            self.assertIsNotNone(get_organization_by_short_name("orgX"))
            data = parse_json(response)
            new_course_key = CourseKey.from_string(data['course_key'])
            course_orgs = get_course_organizations(new_course_key)
            self.assertEqual(len(course_orgs), 1)
            self.assertEqual(course_orgs[0]['short_name'], 'orgX')