Skip to content
This repository has been archived by the owner on Oct 19, 2024. It is now read-only.

Tests v2 recreate #760

Merged
merged 13 commits into from
Nov 25, 2023
Merged

Tests v2 recreate #760

merged 13 commits into from
Nov 25, 2023

Conversation

thesuzerain
Copy link
Contributor

@thesuzerain thesuzerain commented Nov 17, 2023

  • Re-adds v2 testing- allows as many tests as possible to test in both V2 and V3 APIs. Any test that uses the test_environment_all function will perform the test with both APIs.

  • Diff # is misleading. This also makes tests more consistent across the board and using the same format: a closure that can be called multiple times for each API. Because so many lines were indented, the diff looks quite large. (maybe closer to 1k-2k lines in actuality, and most of that is repeated changes across many tests).

(The substantial reviewable parts are the ApiBuildable, Api, etc traits and that setup)

@thesuzerain thesuzerain marked this pull request as ready for review November 18, 2023 01:50
@thesuzerain thesuzerain mentioned this pull request Nov 23, 2023
Comment on lines 103 to 110
// Handle project type via file extension prediction
let mut project_type = None;
for file_part in &legacy_create.file_parts {
if let Some(ext) = file_part.split('.').last() {
match ext {
"jar" => {
project_type = Some("mod");
break;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see other pr, should probably port this over. we should only handle this for modpack .mrpack files

@Geometrically Geometrically merged commit 172b93d into master Nov 25, 2023
7 checks passed
@Geometrically Geometrically deleted the tests-v2-recreate branch November 25, 2023 21:42
thesuzerain added a commit that referenced this pull request Dec 5, 2023
* added common project information; setup for v2 test change

* all tests now use with_test_environment

* progress, failing

* finished re-adding tests

* prepare

* cargo sqlx prepare -- --tests

* fmt; clippy; prepare

* sqlx prepare

* adds version_create fix and corresponding test

* merge fixes; rev

* fmt, clippy, prepare

* test cargo sqlx prepare
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants