Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support standalone runtimes outside lune; fallback to uncolored print if runtime not found #7

Open
deviaze opened this issue Dec 7, 2024 · 3 comments

Comments

@deviaze
Copy link

deviaze commented Dec 7, 2024

As discussed on the ROSS OSS discord, we can make the reporter somewhat more runtime-agnostic in the following manner:

"I'm thinking we extract an interface to generically define "print_color", then define the few colors frktest uses and pull out the implementation in separate _lune.luau and _seal.luau files? They can be conditionally required based on the detected runtime and if no runtime is found, fallback to just print without color?" - itsfrank

This would allow first-class support for other runtimes such as Zune and seal

@itsfrank
Copy link
Owner

itsfrank commented Dec 8, 2024

I made the reporter generic in this branch: https://github.com/itsfrank/frktest/tree/generic-reporter

What is missing for seal support is the following:

  1. Implement runtime detection for seal here:
  2. Implement seal's color function here:

If you can just let me know how to achieve those with seal I can handle it and merge this into main

@itsfrank
Copy link
Owner

itsfrank commented Dec 8, 2024

#8 was merged making the whole library platform-agnostic, now we just need to add seal color implementation

@itsfrank
Copy link
Owner

itsfrank commented Dec 8, 2024

Feel free to open a PR adding seal as a supported runtime! Once you do, I can quickly follow-up with readme updates.

In addition to the 2 locations above, you can add a comment showing how to exit with non-0 code here:

-- require("@lune/process").exit(1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants