Commit 2f275f31 by Zia Fazal

fixed scenario when tests run using cached sql schema

parent 7cdeb330
......@@ -186,7 +186,13 @@ def fulfill_course_milestone(course_key, user):
if not settings.FEATURES.get('MILESTONES_APP', False):
return None
from milestones import api as milestones_api
course_milestones = milestones_api.get_course_milestones(course_key=course_key, relationship="fulfills")
from milestones.exceptions import InvalidMilestoneRelationshipTypeException
try:
course_milestones = milestones_api.get_course_milestones(course_key=course_key, relationship="fulfills")
except InvalidMilestoneRelationshipTypeException:
# we have not seeded milestone relationship types
seed_milestone_relationship_types()
course_milestones = milestones_api.get_course_milestones(course_key=course_key, relationship="fulfills")
for milestone in course_milestones:
milestones_api.add_user_milestone({'id': user.id}, milestone)
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -21,7 +21,7 @@
LOCK TABLES `django_migrations` WRITE;
/*!40000 ALTER TABLE `django_migrations` DISABLE KEYS */;
INSERT INTO `django_migrations` VALUES (1,'contenttypes','0001_initial','2015-11-18 15:37:03.679215'),(2,'auth','0001_initial','2015-11-18 15:37:04.239453'),(3,'admin','0001_initial','2015-11-18 15:37:04.375156'),(4,'assessment','0001_initial','2015-11-18 15:37:09.037208'),(5,'contenttypes','0002_remove_content_type_name','2015-11-18 15:37:09.345424'),(6,'auth','0002_alter_permission_name_max_length','2015-11-18 15:37:09.479742'),(7,'auth','0003_alter_user_email_max_length','2015-11-18 15:37:09.677049'),(8,'auth','0004_alter_user_username_opts','2015-11-18 15:37:09.805606'),(9,'auth','0005_alter_user_last_login_null','2015-11-18 15:37:09.949394'),(10,'auth','0006_require_contenttypes_0002','2015-11-18 15:37:09.978283'),(11,'branding','0001_initial','2015-11-18 15:37:10.295010'),(12,'bulk_email','0001_initial','2015-11-18 15:37:10.849873'),(13,'bulk_email','0002_data__load_course_email_template','2015-11-18 15:37:10.939652'),(14,'certificates','0001_initial','2015-11-18 15:37:12.698538'),(15,'certificates','0002_data__certificatehtmlviewconfiguration_data','2015-11-18 15:37:12.746221'),(16,'certificates','0003_data__default_modes','2015-11-18 15:37:13.182516'),(17,'commerce','0001_data__add_ecommerce_service_user','2015-11-18 15:37:13.269990'),(18,'cors_csrf','0001_initial','2015-11-18 15:37:13.459604'),(19,'course_action_state','0001_initial','2015-11-18 15:37:14.011267'),(20,'course_groups','0001_initial','2015-11-18 15:37:15.487063'),(21,'course_modes','0001_initial','2015-11-18 15:37:15.719347'),(22,'course_overviews','0001_initial','2015-11-18 15:37:15.932886'),(23,'course_structures','0001_initial','2015-11-18 15:37:16.000954'),(24,'courseware','0001_initial','2015-11-18 15:37:18.771429'),(25,'credit','0001_initial','2015-11-18 15:37:21.519361'),(26,'dark_lang','0001_initial','2015-11-18 15:37:21.846133'),(27,'dark_lang','0002_data__enable_on_install','2015-11-18 15:37:21.995633'),(28,'default','0001_initial','2015-11-18 15:37:23.147337'),(29,'default','0002_add_related_name','2015-11-18 15:37:23.421429'),(30,'default','0003_alter_email_max_length','2015-11-18 15:37:23.512312'),(31,'django_comment_common','0001_initial','2015-11-18 15:37:24.320730'),(32,'django_notify','0001_initial','2015-11-18 15:37:25.685195'),(33,'django_openid_auth','0001_initial','2015-11-18 15:37:26.276837'),(34,'edx_proctoring','0001_initial','2015-11-18 15:37:30.965630'),(35,'edxval','0001_initial','2015-11-18 15:37:32.899299'),(36,'edxval','0002_data__default_profiles','2015-11-18 15:37:32.962490'),(37,'embargo','0001_initial','2015-11-18 15:37:34.781531'),(38,'embargo','0002_data__add_countries','2015-11-18 15:37:36.006428'),(39,'external_auth','0001_initial','2015-11-18 15:37:36.857447'),(40,'foldit','0001_initial','2015-11-18 15:37:38.106002'),(41,'instructor_task','0001_initial','2015-11-18 15:37:38.670378'),(42,'licenses','0001_initial','2015-11-18 15:37:39.225872'),(43,'lms_xblock','0001_initial','2015-11-18 15:37:39.674372'),(44,'milestones','0001_initial','2015-11-18 15:37:41.240336'),(45,'milestones','0002_data__seed_relationship_types','2015-11-18 15:37:41.287383'),(46,'mobile_api','0001_initial','2015-11-18 15:37:41.822343'),(47,'notes','0001_initial','2015-11-18 15:37:42.381389'),(48,'oauth2','0001_initial','2015-11-18 15:37:45.638217'),(49,'oauth2_provider','0001_initial','2015-11-18 15:37:46.173938'),(50,'oauth_provider','0001_initial','2015-11-18 15:37:47.398936'),(51,'organizations','0001_initial','2015-11-18 15:37:47.863329'),(52,'programs','0001_initial','2015-11-18 15:37:48.427080'),(53,'psychometrics','0001_initial','2015-11-18 15:37:48.987109'),(54,'self_paced','0001_initial','2015-11-18 15:37:49.523078'),(55,'sessions','0001_initial','2015-11-18 15:37:49.646106'),(56,'student','0001_initial','2015-11-18 15:38:05.543390'),(57,'shoppingcart','0001_initial','2015-11-18 15:38:21.727512'),(58,'sites','0001_initial','2015-11-18 15:38:21.837391'),(59,'splash','0001_initial','2015-11-18 15:38:23.244678'),(60,'status','0001_initial','2015-11-18 15:38:24.981737'),(61,'submissions','0001_initial','2015-11-18 15:38:26.499689'),(62,'survey','0001_initial','2015-11-18 15:38:28.962457'),(63,'teams','0001_initial','2015-11-18 15:38:31.641489'),(64,'third_party_auth','0001_initial','2015-11-18 15:38:35.861826'),(65,'track','0001_initial','2015-11-18 15:38:35.952939'),(66,'user_api','0001_initial','2015-11-18 15:38:42.846323'),(67,'util','0001_initial','2015-11-18 15:38:43.780691'),(68,'util','0002_data__default_rate_limit_config','2015-11-18 15:38:43.844470'),(69,'verify_student','0001_initial','2015-11-18 15:39:02.098134'),(70,'wiki','0001_initial','2015-11-18 15:39:50.801336'),(71,'workflow','0001_initial','2015-11-18 15:39:51.336698'),(72,'xblock_django','0001_initial','2015-11-18 15:39:52.487567'),(73,'contentstore','0001_initial','2015-11-18 15:40:36.154872'),(74,'course_creators','0001_initial','2015-11-18 15:40:36.715711'),(75,'xblock_config','0001_initial','2015-11-18 15:40:38.167185');
INSERT INTO `django_migrations` VALUES (1,'contenttypes','0001_initial','2015-12-31 14:56:00.696699'),(2,'auth','0001_initial','2015-12-31 14:56:01.170600'),(3,'admin','0001_initial','2015-12-31 14:56:01.299892'),(4,'assessment','0001_initial','2015-12-31 14:56:06.155369'),(5,'contenttypes','0002_remove_content_type_name','2015-12-31 14:56:06.409538'),(6,'auth','0002_alter_permission_name_max_length','2015-12-31 14:56:06.515068'),(7,'auth','0003_alter_user_email_max_length','2015-12-31 14:56:06.610329'),(8,'auth','0004_alter_user_username_opts','2015-12-31 14:56:06.687373'),(9,'auth','0005_alter_user_last_login_null','2015-12-31 14:56:06.813648'),(10,'auth','0006_require_contenttypes_0002','2015-12-31 14:56:06.826022'),(11,'bookmarks','0001_initial','2015-12-31 14:56:07.366960'),(12,'branding','0001_initial','2015-12-31 14:56:07.712825'),(13,'bulk_email','0001_initial','2015-12-31 14:56:08.342193'),(14,'bulk_email','0002_data__load_course_email_template','2015-12-31 14:56:08.505805'),(15,'instructor_task','0001_initial','2015-12-31 14:56:08.912332'),(16,'certificates','0001_initial','2015-12-31 14:56:11.217554'),(17,'certificates','0002_data__certificatehtmlviewconfiguration_data','2015-12-31 14:56:11.244003'),(18,'certificates','0003_data__default_modes','2015-12-31 14:56:11.290756'),(19,'certificates','0004_certificategenerationhistory','2015-12-31 14:56:11.491562'),(20,'certificates','0005_auto_20151208_0801','2015-12-31 14:56:11.626958'),(21,'certificates','0006_certificatetemplateasset_asset_slug','2015-12-31 14:56:11.720518'),(22,'commerce','0001_data__add_ecommerce_service_user','2015-12-31 14:56:11.757252'),(23,'cors_csrf','0001_initial','2015-12-31 14:56:11.926018'),(24,'course_action_state','0001_initial','2015-12-31 14:56:12.330811'),(25,'course_groups','0001_initial','2015-12-31 14:56:13.807718'),(26,'course_modes','0001_initial','2015-12-31 14:56:13.997693'),(27,'course_modes','0002_coursemode_expiration_datetime_is_explicit','2015-12-31 14:56:14.093722'),(28,'course_modes','0003_auto_20151113_1443','2015-12-31 14:56:14.131388'),(29,'course_modes','0004_auto_20151113_1457','2015-12-31 14:56:14.335292'),(30,'course_modes','0005_auto_20151217_0958','2015-12-31 14:56:14.495286'),(31,'course_overviews','0001_initial','2015-12-31 14:56:14.630819'),(32,'course_overviews','0002_add_course_catalog_fields','2015-12-31 14:56:14.982549'),(33,'course_overviews','0003_courseoverviewgeneratedhistory','2015-12-31 14:56:15.030490'),(34,'course_overviews','0004_courseoverview_org','2015-12-31 14:56:15.113722'),(35,'course_overviews','0005_delete_courseoverviewgeneratedhistory','2015-12-31 14:56:15.143943'),(36,'course_overviews','0006_courseoverviewimageset','2015-12-31 14:56:15.254940'),(37,'course_overviews','0007_courseoverviewimageconfig','2015-12-31 14:56:15.450756'),(38,'course_structures','0001_initial','2015-12-31 14:56:15.506341'),(39,'courseware','0001_initial','2015-12-31 14:56:18.346538'),(40,'credit','0001_initial','2015-12-31 14:56:20.423456'),(41,'dark_lang','0001_initial','2015-12-31 14:56:20.691321'),(42,'dark_lang','0002_data__enable_on_install','2015-12-31 14:56:20.722202'),(43,'default','0001_initial','2015-12-31 14:56:21.476817'),(44,'default','0002_add_related_name','2015-12-31 14:56:21.732324'),(45,'default','0003_alter_email_max_length','2015-12-31 14:56:21.814437'),(46,'django_comment_common','0001_initial','2015-12-31 14:56:22.536942'),(47,'django_notify','0001_initial','2015-12-31 14:56:24.596629'),(48,'django_openid_auth','0001_initial','2015-12-31 14:56:24.972976'),(49,'edx_proctoring','0001_initial','2015-12-31 14:56:30.301516'),(50,'edx_proctoring','0002_proctoredexamstudentattempt_is_status_acknowledged','2015-12-31 14:56:30.658999'),(51,'edxval','0001_initial','2015-12-31 14:56:31.901318'),(52,'edxval','0002_data__default_profiles','2015-12-31 14:56:31.985614'),(53,'embargo','0001_initial','2015-12-31 14:56:33.476417'),(54,'embargo','0002_data__add_countries','2015-12-31 14:56:34.169435'),(55,'external_auth','0001_initial','2015-12-31 14:56:34.976587'),(56,'lms_xblock','0001_initial','2015-12-31 14:56:35.342783'),(57,'milestones','0001_initial','2015-12-31 14:56:37.717602'),(58,'milestones','0002_data__seed_relationship_types','2015-12-31 14:56:37.771111'),(59,'mobile_api','0001_initial','2015-12-31 14:56:38.159420'),(60,'notes','0001_initial','2015-12-31 14:56:38.666731'),(61,'oauth2','0001_initial','2015-12-31 14:56:40.986260'),(62,'oauth2_provider','0001_initial','2015-12-31 14:56:41.385485'),(63,'oauth_provider','0001_initial','2015-12-31 14:56:42.439047'),(64,'organizations','0001_initial','2015-12-31 14:56:42.776842'),(65,'programs','0001_initial','2015-12-31 14:56:43.190769'),(66,'programs','0002_programsapiconfig_cache_ttl','2015-12-31 14:56:43.616792'),(67,'programs','0003_auto_20151120_1613','2015-12-31 14:56:45.292878'),(68,'self_paced','0001_initial','2015-12-31 14:56:45.742961'),(69,'sessions','0001_initial','2015-12-31 14:56:45.834774'),(70,'student','0001_initial','2015-12-31 14:57:00.707670'),(71,'shoppingcart','0001_initial','2015-12-31 14:57:15.041286'),(72,'shoppingcart','0002_auto_20151208_1034','2015-12-31 14:57:16.163983'),(73,'shoppingcart','0003_auto_20151217_0958','2015-12-31 14:57:17.314819'),(74,'sites','0001_initial','2015-12-31 14:57:17.389091'),(75,'splash','0001_initial','2015-12-31 14:57:18.037349'),(76,'status','0001_initial','2015-12-31 14:57:19.826410'),(77,'student','0002_auto_20151208_1034','2015-12-31 14:57:21.147521'),(78,'submissions','0001_initial','2015-12-31 14:57:23.354858'),(79,'submissions','0002_auto_20151119_0913','2015-12-31 14:57:23.620278'),(80,'survey','0001_initial','2015-12-31 14:57:24.698404'),(81,'teams','0001_initial','2015-12-31 14:57:26.825637'),(82,'third_party_auth','0001_initial','2015-12-31 14:57:30.487810'),(83,'track','0001_initial','2015-12-31 14:57:30.566408'),(84,'user_api','0001_initial','2015-12-31 14:57:35.956967'),(85,'util','0001_initial','2015-12-31 14:57:36.691350'),(86,'util','0002_data__default_rate_limit_config','2015-12-31 14:57:36.747714'),(87,'verify_student','0001_initial','2015-12-31 14:57:46.279873'),(88,'verify_student','0002_auto_20151124_1024','2015-12-31 14:57:47.187739'),(89,'verify_student','0003_auto_20151113_1443','2015-12-31 14:57:47.983638'),(90,'wiki','0001_initial','2015-12-31 14:58:12.991851'),(91,'wiki','0002_remove_article_subscription','2015-12-31 14:58:13.055035'),(92,'workflow','0001_initial','2015-12-31 14:58:13.504017'),(93,'xblock_django','0001_initial','2015-12-31 14:58:14.361722'),(94,'contentstore','0001_initial','2015-12-31 14:58:40.752928'),(95,'course_creators','0001_initial','2015-12-31 14:58:40.919957'),(96,'xblock_config','0001_initial','2015-12-31 14:58:41.443731');
/*!40000 ALTER TABLE `django_migrations` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
......@@ -34,4 +34,4 @@ UNLOCK TABLES;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2015-11-18 15:40:53
-- Dump completed on 2015-12-31 14:58:46
......@@ -386,7 +386,7 @@ CREATE TABLE `auth_permission` (
PRIMARY KEY (`id`),
UNIQUE KEY `content_type_id` (`content_type_id`,`codename`),
CONSTRAINT `auth__content_type_id_508cf46651277a81_fk_django_content_type_id` FOREIGN KEY (`content_type_id`) REFERENCES `django_content_type` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=704 DEFAULT CHARSET=utf8;
) ENGINE=InnoDB AUTO_INCREMENT=710 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `auth_registration`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
......@@ -480,6 +480,43 @@ CREATE TABLE `auth_userprofile` (
CONSTRAINT `auth_userprofile_user_id_4c194f9b5650ad70_fk_auth_user_id` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `bookmarks_bookmark`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookmarks_bookmark` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`created` datetime(6) NOT NULL,
`modified` datetime(6) NOT NULL,
`course_key` varchar(255) NOT NULL,
`usage_key` varchar(255) NOT NULL,
`path` longtext NOT NULL,
`user_id` int(11) NOT NULL,
`xblock_cache_id` int(11) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `bookmarks_bookmark_user_id_7059f67cddd52c9a_uniq` (`user_id`,`usage_key`),
KEY `bookmarks_bookmark_c8235886` (`course_key`),
KEY `bookmarks_bookmark_4a93f0de` (`usage_key`),
KEY `bookmarks_bookmark_d452fbf6` (`xblock_cache_id`),
CONSTRAINT `boo_xblock_cache_id_22d48842487ba2d2_fk_bookmarks_xblockcache_id` FOREIGN KEY (`xblock_cache_id`) REFERENCES `bookmarks_xblockcache` (`id`),
CONSTRAINT `bookmarks_bookmark_user_id_33914fa9accf01cb_fk_auth_user_id` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `bookmarks_xblockcache`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookmarks_xblockcache` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`created` datetime(6) NOT NULL,
`modified` datetime(6) NOT NULL,
`course_key` varchar(255) NOT NULL,
`usage_key` varchar(255) NOT NULL,
`display_name` varchar(255) NOT NULL,
`paths` longtext NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `usage_key` (`usage_key`),
KEY `bookmarks_xblockcache_c8235886` (`course_key`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `branding_brandingapiconfig`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......@@ -650,6 +687,24 @@ CREATE TABLE `certificates_certificategenerationcoursesetting` (
KEY `certificates_certificategenerationcoursesetting_c8235886` (`course_key`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `certificates_certificategenerationhistory`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `certificates_certificategenerationhistory` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`created` datetime(6) NOT NULL,
`modified` datetime(6) NOT NULL,
`course_id` varchar(255) NOT NULL,
`is_regeneration` tinyint(1) NOT NULL,
`generated_by_id` int(11) NOT NULL,
`instructor_task_id` int(11) NOT NULL,
PRIMARY KEY (`id`),
KEY `certificates_ce_generated_by_id_4679598e2d7d6e10_fk_auth_user_id` (`generated_by_id`),
KEY `D794923145b81064c232a4d0bfe79880` (`instructor_task_id`),
CONSTRAINT `D794923145b81064c232a4d0bfe79880` FOREIGN KEY (`instructor_task_id`) REFERENCES `instructor_task_instructortask` (`id`),
CONSTRAINT `certificates_ce_generated_by_id_4679598e2d7d6e10_fk_auth_user_id` FOREIGN KEY (`generated_by_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `certificates_certificatehtmlviewconfiguration`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......@@ -693,7 +748,9 @@ CREATE TABLE `certificates_certificatetemplateasset` (
`modified` datetime(6) NOT NULL,
`description` varchar(255) DEFAULT NULL,
`asset` varchar(255) NOT NULL,
PRIMARY KEY (`id`)
`asset_slug` varchar(255),
PRIMARY KEY (`id`),
UNIQUE KEY `asset_slug` (`asset_slug`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `certificates_certificatewhitelist`;
......@@ -767,6 +824,7 @@ CREATE TABLE `certificates_generatedcertificate` (
`user_id` int(11) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `certificates_generatedcertificate_user_id_552a0fa6f7d3f7e8_uniq` (`user_id`,`course_id`),
KEY `certificates_generatedcertific_verify_uuid_1b5a14bb83c471ff_uniq` (`verify_uuid`),
CONSTRAINT `certificates_generatedc_user_id_77ed5f7a53121815_fk_auth_user_id` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
......@@ -954,16 +1012,31 @@ CREATE TABLE `course_modes_coursemode` (
`mode_display_name` varchar(255) NOT NULL,
`min_price` int(11) NOT NULL,
`currency` varchar(8) NOT NULL,
`expiration_datetime` datetime(6) DEFAULT NULL,
`expiration_date` date DEFAULT NULL,
`suggested_prices` varchar(255) NOT NULL,
`description` longtext,
`sku` varchar(255) DEFAULT NULL,
`expiration_datetime_is_explicit` tinyint(1) NOT NULL,
`expiration_datetime` datetime(6) DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `course_modes_coursemode_course_id_6fbb1796ace558b4_uniq` (`course_id`,`mode_slug`,`currency`),
KEY `course_modes_coursemode_ea134da7` (`course_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `course_modes_coursemodeexpirationconfig`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `course_modes_coursemodeexpirationconfig` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`change_date` datetime(6) NOT NULL,
`enabled` tinyint(1) NOT NULL,
`verification_window` bigint(20) NOT NULL,
`changed_by_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `course_modes_cour_changed_by_id_4d31fab2bbe98b89_fk_auth_user_id` (`changed_by_id`),
CONSTRAINT `course_modes_cour_changed_by_id_4d31fab2bbe98b89_fk_auth_user_id` FOREIGN KEY (`changed_by_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `course_modes_coursemodesarchive`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......@@ -1016,9 +1089,47 @@ CREATE TABLE `course_overviews_courseoverview` (
`enrollment_domain` longtext,
`invitation_only` tinyint(1) NOT NULL,
`max_student_enrollments_allowed` int(11) DEFAULT NULL,
`announcement` datetime(6),
`catalog_visibility` longtext,
`course_video_url` longtext,
`effort` longtext,
`short_description` longtext,
`org` longtext NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `course_overviews_courseoverviewimageconfig`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `course_overviews_courseoverviewimageconfig` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`change_date` datetime(6) NOT NULL,
`enabled` tinyint(1) NOT NULL,
`small_width` int(11) NOT NULL,
`small_height` int(11) NOT NULL,
`large_width` int(11) NOT NULL,
`large_height` int(11) NOT NULL,
`changed_by_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `course_overviews__changed_by_id_54b19ba1c134af6a_fk_auth_user_id` (`changed_by_id`),
CONSTRAINT `course_overviews__changed_by_id_54b19ba1c134af6a_fk_auth_user_id` FOREIGN KEY (`changed_by_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `course_overviews_courseoverviewimageset`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `course_overviews_courseoverviewimageset` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`created` datetime(6) NOT NULL,
`modified` datetime(6) NOT NULL,
`small_url` longtext NOT NULL,
`large_url` longtext NOT NULL,
`course_overview_id` varchar(255) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `course_overview_id` (`course_overview_id`),
CONSTRAINT `D47baf904f8952eb0e1fafefd558a718` FOREIGN KEY (`course_overview_id`) REFERENCES `course_overviews_courseoverview` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `course_overviews_courseoverviewtab`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......@@ -1445,7 +1556,7 @@ CREATE TABLE `django_content_type` (
`model` varchar(100) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `django_content_type_app_label_45f3b1d93ec8c61c_uniq` (`app_label`,`model`)
) ENGINE=InnoDB AUTO_INCREMENT=234 DEFAULT CHARSET=utf8;
) ENGINE=InnoDB AUTO_INCREMENT=236 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `django_migrations`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
......@@ -1456,7 +1567,7 @@ CREATE TABLE `django_migrations` (
`name` varchar(255) NOT NULL,
`applied` datetime(6) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=76 DEFAULT CHARSET=utf8;
) ENGINE=InnoDB AUTO_INCREMENT=97 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `django_openid_auth_association`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
......@@ -2387,6 +2498,7 @@ CREATE TABLE `proctoring_proctoredexamstudentattempt` (
`review_policy_id` int(11) DEFAULT NULL,
`proctored_exam_id` int(11) NOT NULL,
`user_id` int(11) NOT NULL,
`is_status_acknowledged` tinyint(1) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `proctoring_proctoredexamstudentatt_user_id_15d13fa8dac316a0_uniq` (`user_id`,`proctored_exam_id`),
KEY `D5e0a120c32f715bfe04a0a57f399ec0` (`proctored_exam_id`),
......@@ -2455,8 +2567,12 @@ CREATE TABLE `programs_programsapiconfig` (
`internal_service_url` varchar(200) NOT NULL,
`public_service_url` varchar(200) NOT NULL,
`api_version_number` int(11) NOT NULL,
`enable_student_dashboard` tinyint(1) DEFAULT NULL,
`enable_student_dashboard` tinyint(1) NOT NULL,
`changed_by_id` int(11) DEFAULT NULL,
`cache_ttl` int(10) unsigned NOT NULL,
`authoring_app_css_path` varchar(255) NOT NULL,
`authoring_app_js_path` varchar(255) NOT NULL,
`enable_studio_tab` tinyint(1) NOT NULL,
PRIMARY KEY (`id`),
KEY `programs_programsa_changed_by_id_b7c3b49d5c0dcd3_fk_auth_user_id` (`changed_by_id`),
CONSTRAINT `programs_programsa_changed_by_id_b7c3b49d5c0dcd3_fk_auth_user_id` FOREIGN KEY (`changed_by_id`) REFERENCES `auth_user` (`id`)
......@@ -3229,6 +3345,22 @@ CREATE TABLE `submissions_score` (
CONSTRAINT `subm_submission_id_3fc975fe88442ff7_fk_submissions_submission_id` FOREIGN KEY (`submission_id`) REFERENCES `submissions_submission` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `submissions_scoreannotation`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `submissions_scoreannotation` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`annotation_type` varchar(255) NOT NULL,
`creator` varchar(255) NOT NULL,
`reason` longtext NOT NULL,
`score_id` int(11) NOT NULL,
PRIMARY KEY (`id`),
KEY `submissions_sc_score_id_7b5ef248552cb857_fk_submissions_score_id` (`score_id`),
KEY `submissions_scoreannotation_fd685234` (`annotation_type`),
KEY `submissions_scoreannotation_ee243325` (`creator`),
CONSTRAINT `submissions_sc_score_id_7b5ef248552cb857_fk_submissions_score_id` FOREIGN KEY (`score_id`) REFERENCES `submissions_score` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `submissions_scoresummary`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......@@ -3580,6 +3712,7 @@ CREATE TABLE `verify_student_historicalverificationdeadline` (
`history_date` datetime(6) NOT NULL,
`history_type` varchar(1) NOT NULL,
`history_user_id` int(11) DEFAULT NULL,
`deadline_is_explicit` tinyint(1) NOT NULL,
PRIMARY KEY (`history_id`),
KEY `verify_student__history_user_id_1e374d24cb7902c2_fk_auth_user_id` (`history_user_id`),
KEY `verify_student_historicalverificationdeadline_b80bb774` (`id`),
......@@ -3702,6 +3835,7 @@ CREATE TABLE `verify_student_verificationdeadline` (
`modified` datetime(6) NOT NULL,
`course_key` varchar(255) NOT NULL,
`deadline` datetime(6) NOT NULL,
`deadline_is_explicit` tinyint(1) NOT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `course_key` (`course_key`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
......@@ -3804,18 +3938,6 @@ CREATE TABLE `wiki_articlerevision` (
CONSTRAINT `wiki_articlerevision_user_id_183520686b6ead55_fk_auth_user_id` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `wiki_articlesubscription`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `wiki_articlesubscription` (
`articleplugin_ptr_id` int(11) NOT NULL,
`subscription_ptr_id` int(11) NOT NULL,
PRIMARY KEY (`articleplugin_ptr_id`),
UNIQUE KEY `subscription_ptr_id` (`subscription_ptr_id`),
CONSTRAINT `D3cd26aee5a69a796bee9c6aeab7e317` FOREIGN KEY (`subscription_ptr_id`) REFERENCES `notify_subscription` (`subscription_id`),
CONSTRAINT `w_articleplugin_ptr_id_489742a9a302c93d_fk_wiki_articleplugin_id` FOREIGN KEY (`articleplugin_ptr_id`) REFERENCES `wiki_articleplugin` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
DROP TABLE IF EXISTS `wiki_attachment`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
......
......@@ -28,7 +28,7 @@ DB_CACHE_DIR="common/test/db_cache"
echo "CREATE DATABASE IF NOT EXISTS edxtest;" | mysql -u root
# Clear out the test database
./manage.py lms --settings bok_choy reset_db --traceback --noinput
./manage.py lms --settings bok_choy flush --traceback --noinput
# If there are cached database schemas/data, load them
if [[ -f $DB_CACHE_DIR/bok_choy_schema.sql && -f $DB_CACHE_DIR/bok_choy_migrations_data.sql && -f $DB_CACHE_DIR/bok_choy_data.json ]]; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment