-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #230 from AlexB52/v2.0
* listen to user inputs in executable (#213) * Listen to user inputs in executable * 'h' or 'help' -> Prints help * 'p' or 'pause' -> Pauses Retest. Tests aren't run until unpaused. * 'u' or 'unpause' -> Unpauses Retest * <Enter> -> Runs last changed triggered command * 'ra', 'run all' -> Runs all tests * 'e' or 'exit' -> Exits Retest * Create version 2.0.0.pre * Fix gets chomp no method error (#217) * Convert nil to string * Update version to v2 in tests * Update the help prompt * Refactor Runner#run_all_tests to raise unless for TestRunner (#219) * Manage stdin based on the process running (#220) * Create Program#run_synchronously (#221) * Create pre release 3 (#223) * Multiplex stdin between user input and listen input (#224) * Reverse Listen communication and restrict its usage as an automatic input * Delete Program#run_synchronously * Clear input dependencies on runner and prompt & refactor program * Create version v2.0.0.pre3 * v2 - Refactor runners (#226) * Update file selection logs * Create Command::Hardcoded * Use the Command::Hardcoded command * Update Runner#run arguments * Delete all runners except Runner * Switch to bundler 2.3.27 * Standardize ruby version in ci definition * Remove clear terminal call * Ask user which tests to run We add TTY::Prompt dependency for ease of user experience * Refactoring * Cleanup runner and commands * Remove all_test_runner * Refactor format batch of Ruby and Rake * V2 - Force selection of test files to run (#228) * Remove command dependency from program objects * Force selection of tests and run them on file changes * Small fixes: * Clear terminal window from the executable instead * Add a hint to reset when on forced selection * Update interactive help * Run last command on Enter * Create version 2.0.0.pre4 * Add Watchexec watcher as default when installed on machine * Revert to Bundler 2.3.27 * Create --exts and Delete --ext option We allow to pass a list of extensions instead of a regex and build the regex from the options instead of the user. This is simpler and easier for the user. * Display watcher used * Switch Listen to Wrapper Watcher::Default * Override watchexec with default watcher on CI * Allow VersionControl.files to take file extensions * Default to watchexec when installed * Remove .puts (for now) * Remove watchexec feature specs (for now) * Fix order of file change events in watchexec watcher (#231) * V2/watchexec feature test (#232) * Create Watchexec feature specs * Build watchexec in separate image * Add command to build watchexec image * Merge ruby-app to use both watchexec and listen watchers (#233) * Create version 2.0.0.pre5 * Add Interactive Feature tests (#234) * Fix Runner#last_command when running all tests * Refactor bundler-app helpers and test command * Add interactive feature tests * Pause/Unpause * Run all * Force selection * Start / Help * Run last command * V2/refactor test helper (#235) * Enable new test helper for all feature specs * Refactor all feature specs * Fix rails-app feature spec
- Loading branch information
Showing
107 changed files
with
2,299 additions
and
1,493 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ gemspec | |
|
||
gem "rake", "~> 13.0" | ||
gem "minitest", "~> 5.0" | ||
gem "byebug" | ||
gem "byebug", require: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/usr/bin/env bash | ||
|
||
docker buildx build \ | ||
--platform linux/amd64,linux/arm64 \ | ||
-t ghcr.io/alexb52/slim-bullseye-watchexec:latest \ | ||
-f builds/dockerfiles/WatchexecSlimBullseye \ | ||
--push . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,14 @@ | ||
#!/usr/bin/env bash | ||
|
||
FOLDER="features/bundler-app" | ||
|
||
bundle install | ||
bundle exec rake build | ||
cp -R features/support features/bundler-app/retest | ||
ls -t pkg | head -n1 | xargs -I {} mv pkg/{} features/bundler-app/retest.gem | ||
docker compose -f features/bundler-app/docker-compose.yml up --build --exit-code-from retest | ||
ls -t pkg | head -n1 | xargs -I {} mv pkg/{} "$FOLDER/retest.gem" | ||
|
||
if [[ "$1" == "--no-build" ]]; then | ||
docker compose -f "$FOLDER/docker-compose.yml" up --exit-code-from retest | ||
else | ||
docker compose -f "$FOLDER/docker-compose.yml" up --build --exit-code-from retest | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Stage 1: Build watchexec with Rust | ||
FROM rust:1.83.0-slim-bullseye AS rust-builder | ||
|
||
# Install necessary dependencies for Rust | ||
RUN apt-get update -qq && \ | ||
apt-get install --no-install-recommends -y build-essential git | ||
|
||
# Install watchexec | ||
RUN cargo install watchexec-cli | ||
|
||
# Verify installation | ||
RUN watchexec --version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# fibonacci.rb | ||
class Fibonacci | ||
def self.calculate(n) | ||
raise ArgumentError, "Input must be a non-negative integer." unless n.is_a?(Integer) && n >= 0 | ||
return n if n <= 1 | ||
|
||
a, b = 0, 1 | ||
(n - 1).times { a, b = b, a + b } | ||
b | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.