@@ -0,0 +1,1425 @@
+package org.ensembl.healthcheck.testcase.eg_core;%0A%0Aimport java.sql.Connection;%0A%0Aimport org.ensembl.healthcheck.DatabaseType;%0Aimport org.ensembl.healthcheck.ReportManager;%0Aimport org.ensembl.healthcheck.Team;%0Aimport org.ensembl.healthcheck.util.DBUtils;%0A%0Apublic class EGCompareVariationSchema extends EGAbstractCompareSchema %7B%0A%0A%09public EGCompareVariationSchema() %7B%0A%09%09setTeamResponsible(Team.VARIATION);%0A%09%09addAppliesToType(DatabaseType.VARIATION);%0A%09%7D%0A%0A%09@Override%0A%09protected String getDefinitionFileKey() %7B%0A%09%09return %22variation_schema.file%22;%0A%09%7D%0A%0A%09@Override%0A%09protected String getMasterSchemaKey() %7B%0A%09%09return %22master.variation_schema%22;%0A%09%7D%0A%0A%09@Override%0A%09protected boolean assertSchemaCompatibility(Connection masterCon,%0A%09%09%09Connection checkCon) %7B%0A%09%09%0A%09%09String sql = %22SELECT meta_value FROM meta WHERE meta_key='schema_type'%22;%0A%09%09String schemaVersionCheck  = DBUtils.getRowColumnValue(checkCon, sql);%0A%09%09String schemaVersionMaster = DBUtils.getRowColumnValue(masterCon, sql);%0A%09%09%0A%09%09if (!schemaVersionCheck.equals(%22variation%22)) %7B%0A%09%09%09%0A%09%09%09ReportManager.problem(this, checkCon,%0A%09%09%09%09%22Database schema type error: The schema type of your database %22%0A%09%09%09%09+ %22is not variation.%22 %0A%09%09%09);%0A%09%09%09return false;%0A%09%09%7D%0A%09%09if (!schemaVersionMaster.equals(%22variation%22)) %7B%0A%09%09%09%0A%09%09%09ReportManager.problem(this, checkCon,%0A%09%09%09%09%22Database schema type error: The schema type of the master %22%0A%09%09%09%09+ %22database is not variation.%22 %0A%09%09%09);%0A%09%09%09return false;%0A%09%09%7D%0A%09%09return true;%0A%09%7D%0A%7D%0A

Test for variation database schema. Produces a patch.