diff options
| author | Junegunn Choi <junegunn.c@gmail.com> | 2025-02-02 22:54:53 +0900 |
|---|---|---|
| committer | Junegunn Choi <junegunn.c@gmail.com> | 2025-02-02 23:10:53 +0900 |
| commit | c1470a51b84283db661acfbb70d1323e86ca7bf8 (patch) | |
| tree | de998e23d1da8e9e8ee6fc9dde4974067c24f3d9 | |
| parent | 6ee31d5dc5b228144c5dee599a2926c128ceb601 (diff) | |
| download | fzf-c1470a51b84283db661acfbb70d1323e86ca7bf8.tar.gz | |
Update Dockerfile
| -rw-r--r-- | .github/workflows/linux.yml | 2 | ||||
| -rw-r--r-- | Dockerfile | 6 | ||||
| -rw-r--r-- | test/test_core.rb | 13 | ||||
| -rw-r--r-- | test/test_filter.rb | 5 |
4 files changed, 17 insertions, 9 deletions
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 7e58bb49..d9b9fe2d 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -16,7 +16,7 @@ env: jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 with: @@ -1,5 +1,5 @@ -FROM ubuntu:24.04 -RUN apt-get update -y && apt install -y git make golang zsh fish ruby tmux +FROM rubylang/ruby:3.4.1-noble +RUN apt-get update -y && apt install -y git make golang zsh fish tmux RUN gem install --no-document -v 5.22.3 minitest RUN echo '. /usr/share/bash-completion/completions/git' >> ~/.bashrc RUN echo '. ~/.bashrc' >> ~/.bash_profile @@ -9,4 +9,4 @@ RUN rm -f /etc/bash.bashrc COPY . /fzf RUN cd /fzf && make install && ./install --all ENV LANG=C.UTF-8 -CMD ["bash", "-ic", "tmux new 'set -o pipefail; ruby /fzf/test/test_go.rb | tee out && touch ok' && cat out && [ -e ok ]"] +CMD ["bash", "-ic", "tmux new 'set -o pipefail; ruby /fzf/test/runner.rb | tee out && touch ok' && cat out && [ -e ok ]"] diff --git a/test/test_core.rb b/test/test_core.rb index 4d91b634..276fa03d 100644 --- a/test/test_core.rb +++ b/test/test_core.rb @@ -1652,4 +1652,17 @@ class TestCore < TestInteractive assert_equal expected, to_vars(lines).slice(*expected.keys) end end + + def test_abort_action_chain + tmux.send_keys %(seq 100 | #{FZF} --bind 'load:accept+up+up' > #{tempname}), :Enter + wait do + assert_path_exists tempname + assert_equal '1', File.read(tempname).chomp + end + tmux.send_keys %(seq 100 | #{FZF} --bind 'load:abort+become(echo {})' > #{tempname}), :Enter + wait do + assert_path_exists tempname + assert_equal '', File.read(tempname).chomp + end + end end diff --git a/test/test_filter.rb b/test/test_filter.rb index ceb2c8cd..dc66ec00 100644 --- a/test/test_filter.rb +++ b/test/test_filter.rb @@ -299,9 +299,4 @@ class TestFilter < TestBase assert_equal expected, result end end - - def test_abort_action_chain - assert_equal '1', `seq 100 | #{FZF} --bind 'load:accept+up+up'`.chomp - assert_equal '', `seq 100 | #{FZF} --bind 'load:abort+become(echo {})'`.chomp - end end |
