Skip to content

Commit

Permalink
test(Feature Amounts): Fixes upload feature shapefile after undoing l…
Browse files Browse the repository at this point in the history
…egacy project hack
  • Loading branch information
KevSanchez committed Oct 26, 2023
1 parent b57c969 commit 0214369
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ test(`custom feature csv upload`, async () => {
await fixtures.ThenNewFeaturesAreCreated();
await fixtures.ThenNewFeaturesAmountsAreCreated();
await fixtures.ThenFeatureUploadRegistryIsCleared();
await fixtures.ThenProjectSourcesIsSetToLegacyProject();
});

test('custom feature csv upload when project not found', async () => {
Expand Down
11 changes: 0 additions & 11 deletions api/apps/api/test/upload-feature/upload-feature.fixtures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import { GivenProjectsPuExists } from '../../../geoprocessing/test/steps/given-p
import { HttpStatus } from '@nestjs/common';
import { GeoFeatureTag } from '@marxan-api/modules/geo-feature-tags/geo-feature-tag.api.entity';
import { tagMaxlength } from '@marxan-api/modules/geo-feature-tags/dto/update-geo-feature-tag.dto';
import { Project } from '@marxan-api/modules/projects/project.api.entity';

export const getFixtures = async () => {
const app = await bootstrapApplication();
Expand Down Expand Up @@ -50,10 +49,6 @@ export const getFixtures = async () => {
getRepositoryToken(GeoFeature, DbConnections.default),
);

const projectsRepository: Repository<Project> = app.get(
getRepositoryToken(Project, DbConnections.default),
);

const featuresAmounsGeoDbRepository: Repository<GeoFeatureGeometry> = app.get(
getRepositoryToken(GeoFeatureGeometry, DbConnections.geoprocessingDB),
);
Expand Down Expand Up @@ -391,11 +386,5 @@ export const getFixtures = async () => {
});
expect(featureImportRegistryRecord).toBeFalsy();
},
ThenProjectSourcesIsSetToLegacyProject: async () => {
const project = await projectsRepository.findOne({
where: { id: projectId },
});
expect(project?.sources).toEqual('legacy_import');
},
};
};

0 comments on commit 0214369

Please sign in to comment.