Skript icon indicating copy to clipboard operation
Skript copied to clipboard

Ignore ExprConfig and ExprScript tests when not using gradlew clean or dev mode is enabled

Open TheLimeGlass opened this issue 1 year ago • 4 comments

Description

When switching from devMode to quickTest any configuration values and present scripts in the scripts folder should be ignored. GitHub actions always uses the clean task.

  • Adds a test environment expression to get any current test mode.
  • Ignore ExprConfig and ExprScript tests when not using gradlew clean or dev mode is enabled.
  • Adds tests size to test results.

Target Minecraft Versions: any Requirements: none Related Issues: none

TheLimeGlass avatar Jan 15 '25 09:01 TheLimeGlass

I don't like ignoring tests because they modify things. I think the answer to this is to just run gradle clean instead of just not running some tests.

sovdeeth avatar Feb 02 '25 18:02 sovdeeth

the test could also be moved to its own subdir with a few dummy scripts. this would fix the issue and make it more consistent

Pikachu920 avatar Feb 03 '25 00:02 Pikachu920

I don't like ignoring tests because they modify things. I think the answer to this is to just run gradle clean instead of just not running some tests.

The tests involving reading the configurations and default scripts are near useless since Skript doesn't modify them during testing, and the files will always be newly generated from the contents of the jar during tests. I feel like those tests were added as a spur to add something relating to JUnit.

Now it's a burden on development when you change those values from a prior test. It should only be accounted for on a newly generated file, to ensure the integrity of the file is as expected. Like this pull request addresses.

Example being changing effect commands needing to be true every time the config.sk gets generated. Ignore it so developers can keep their testing environments as is for their testing configurations.

TheLimeGlass avatar Feb 22 '25 20:02 TheLimeGlass

Also docs gets deleted, now I have to go to another branch and regenerate the docs.

TheLimeGlass avatar Feb 25 '25 21:02 TheLimeGlass