This file contains hidden or 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 configuration was generated by `rubocop --auto-gen-config` | |
| # on 2014-07-03 15:34:29 +0000 using RuboCop version 0.24.1. | |
| # The point is for the user to remove these configuration records | |
| # one by one as the offenses are removed from the code base. | |
| # Note that changes in the inspected code, or installation of new | |
| # versions of RuboCop, may require this file to be generated again. | |
| Style/ClassLength: | |
| Enabled: false | |
| Style/DotPosition: |
This file contains hidden or 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
| [alias] | |
| pr = "!f() { git log --merges --ancestry-path --oneline $1..master | grep 'pull request' | tail -n1 | awk '{ print $5 }'; }; f" |
This file contains hidden or 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
| (def dd (fn [l] (fn[n] (drop n l)))) | |
| (def tails (fn [l] (map (dd l) (range 0 (count l))))) |
This file contains hidden or 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
| # remap prefix from 'C-b' to 'C-a' | |
| unbind C-b | |
| set-option -g prefix C-a | |
| bind-key C-a send-prefix |
This file contains hidden or 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
| it 'calls remote service' do | |
| expect(RemoteServices).to receive(:request_recognize) | |
| .with('88.wav') | |
| .and_return({result: 'ochenta y ocho'}.to_json) | |
| result = VoiceService.recognize('88.wav') | |
| expect(result).to eql('ochenta y ocho') | |
| end |
This file contains hidden or 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
| def test_calls_remote_service | |
| remote_services = Minitest::Mock.new | |
| voice_service = VoiceService.new(remote_services) | |
| remote_services.expect :request_recognize, { result: 'ochenta y ocho' }.to_json, ['88.wav'] | |
| result = voice_service.recognize('88.wav') | |
| assert_equal 'ochenta y ocho', result | |
| remote_services.verify | |
| end |
This file contains hidden or 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
| require "minitest/autorun" | |
| class TestMine < Minitest::Test | |
| def test_1 | |
| field = '*' | |
| expected_result = '*' | |
| assert_equal expected_result, minesweeper(1, 1, field) | |
| end |
OlderNewer