shipit-engine 0.25.1 → 0.26.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/shipit/merge_status_controller.rb +1 -1
  3. data/app/controllers/shipit/stacks_controller.rb +2 -1
  4. data/app/controllers/shipit/webhooks_controller.rb +15 -0
  5. data/app/jobs/shipit/cache_deploy_spec_job.rb +1 -0
  6. data/app/jobs/shipit/perform_task_job.rb +4 -2
  7. data/app/jobs/shipit/refresh_check_runs_job.rb +14 -0
  8. data/app/models/shipit/check_run.rb +71 -0
  9. data/app/models/shipit/commit.rb +25 -2
  10. data/app/models/shipit/deploy_spec.rb +1 -1
  11. data/app/models/shipit/pull_request.rb +2 -2
  12. data/app/models/shipit/status.rb +1 -1
  13. data/app/views/shipit/commits/_commit.html.erb +1 -1
  14. data/db/migrate/20181010150947_create_shipit_check_runs.rb +17 -0
  15. data/lib/shipit.rb +1 -0
  16. data/lib/shipit/octokit_check_runs.rb +9 -0
  17. data/lib/shipit/stack_commands.rb +8 -3
  18. data/lib/shipit/task_commands.rb +2 -3
  19. data/lib/shipit/version.rb +1 -1
  20. data/test/controllers/merge_status_controller_test.rb +15 -0
  21. data/test/controllers/stacks_controller_test.rb +12 -2
  22. data/test/controllers/webhooks_controller_test.rb +9 -0
  23. data/test/dummy/db/schema.rb +17 -1
  24. data/test/fixtures/payloads/check_suite_master.json +194 -0
  25. data/test/fixtures/shipit/check_runs.yml +21 -0
  26. data/test/fixtures/shipit/commits.yml +13 -0
  27. data/test/fixtures/shipit/stacks.yml +8 -0
  28. data/test/jobs/perform_task_job_test.rb +10 -1
  29. data/test/models/commits_test.rb +29 -2
  30. data/test/models/deploy_spec_test.rb +40 -0
  31. data/test/models/shipit/check_run_test.rb +51 -0
  32. data/test/models/status/group_test.rb +3 -3
  33. data/test/unit/deploy_commands_test.rb +5 -1
  34. metadata +128 -118
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shipit-engine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.25.1
4
+ version: 0.26.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jean Boussier
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-11 00:00:00.000000000 Z
11
+ date: 2018-11-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: active_model_serializers
@@ -170,14 +170,14 @@ dependencies:
170
170
  requirements:
171
171
  - - "~>"
172
172
  - !ruby/object:Gem::Version
173
- version: 4.9.0
173
+ version: 4.12.0
174
174
  type: :runtime
175
175
  prerelease: false
176
176
  version_requirements: !ruby/object:Gem::Requirement
177
177
  requirements:
178
178
  - - "~>"
179
179
  - !ruby/object:Gem::Version
180
- version: 4.9.0
180
+ version: 4.12.0
181
181
  - !ruby/object:Gem::Dependency
182
182
  name: omniauth-github
183
183
  requirement: !ruby/object:Gem::Requirement
@@ -524,6 +524,7 @@ files:
524
524
  - app/jobs/shipit/perform_commit_checks_job.rb
525
525
  - app/jobs/shipit/perform_task_job.rb
526
526
  - app/jobs/shipit/purge_old_deliveries_job.rb
527
+ - app/jobs/shipit/refresh_check_runs_job.rb
527
528
  - app/jobs/shipit/refresh_github_user_job.rb
528
529
  - app/jobs/shipit/refresh_pull_request_job.rb
529
530
  - app/jobs/shipit/refresh_statuses_job.rb
@@ -533,6 +534,7 @@ files:
533
534
  - app/models/shipit/anonymous_user.rb
534
535
  - app/models/shipit/api_client.rb
535
536
  - app/models/shipit/application_record.rb
537
+ - app/models/shipit/check_run.rb
536
538
  - app/models/shipit/commit.rb
537
539
  - app/models/shipit/commit_checks.rb
538
540
  - app/models/shipit/commit_deployment.rb
@@ -684,6 +686,7 @@ files:
684
686
  - db/migrate/20180417130436_remove_all_github_hooks.rb
685
687
  - db/migrate/20180802172632_allow_commit_without_author.rb
686
688
  - db/migrate/20180906083930_create_release_statuses.rb
689
+ - db/migrate/20181010150947_create_shipit_check_runs.rb
687
690
  - lib/shipit-engine.rb
688
691
  - lib/shipit.rb
689
692
  - lib/shipit/command.rb
@@ -696,6 +699,7 @@ files:
696
699
  - lib/shipit/flock.rb
697
700
  - lib/shipit/github_app.rb
698
701
  - lib/shipit/null_serializer.rb
702
+ - lib/shipit/octokit_check_runs.rb
699
703
  - lib/shipit/octokit_iterator.rb
700
704
  - lib/shipit/paginator.rb
701
705
  - lib/shipit/rollback_commands.rb
@@ -784,10 +788,12 @@ files:
784
788
  - test/dummy/public/422.html
785
789
  - test/dummy/public/500.html
786
790
  - test/dummy/public/favicon.ico
791
+ - test/fixtures/payloads/check_suite_master.json
787
792
  - test/fixtures/payloads/push_master.json
788
793
  - test/fixtures/payloads/push_not_master.json
789
794
  - test/fixtures/payloads/status_master.json
790
795
  - test/fixtures/shipit/api_clients.yml
796
+ - test/fixtures/shipit/check_runs.yml
791
797
  - test/fixtures/shipit/commit_deployment_statuses.yml
792
798
  - test/fixtures/shipit/commit_deployments.yml
793
799
  - test/fixtures/shipit/commits.yml
@@ -842,6 +848,7 @@ files:
842
848
  - test/models/pull_request_test.rb
843
849
  - test/models/release_statuses_test.rb
844
850
  - test/models/rollbacks_test.rb
851
+ - test/models/shipit/check_run_test.rb
845
852
  - test/models/stacks_test.rb
846
853
  - test/models/status/group_test.rb
847
854
  - test/models/status/missing_test.rb
@@ -894,143 +901,146 @@ signing_key:
894
901
  specification_version: 4
895
902
  summary: Application deployment software
896
903
  test_files:
897
- - test/dummy/public/favicon.ico
898
- - test/dummy/public/500.html
899
- - test/dummy/public/422.html
900
- - test/dummy/public/404.html
901
- - test/dummy/db/seeds.rb
902
- - test/dummy/db/schema.rb
903
- - test/dummy/bin/rake
904
- - test/dummy/bin/bundle
905
- - test/dummy/bin/rails
906
- - test/dummy/bin/setup
907
- - test/dummy/app/views/layouts/application.html.erb
908
- - test/dummy/app/assets/stylesheets/application.css
909
- - test/dummy/app/assets/javascripts/application.js
910
- - test/dummy/app/controllers/application_controller.rb
911
- - test/dummy/app/helpers/application_helper.rb
912
- - test/dummy/config.ru
913
- - test/dummy/Rakefile
914
- - test/dummy/config/application.rb
915
- - test/dummy/config/database.yml
916
- - test/dummy/config/locales/en.yml
917
- - test/dummy/config/secrets.yml
918
- - test/dummy/config/boot.rb
919
- - test/dummy/config/database.mysql.yml
920
- - test/dummy/config/initializers/filter_parameter_logging.rb
921
- - test/dummy/config/initializers/session_store.rb
922
- - test/dummy/config/initializers/backtrace_silencers.rb
923
- - test/dummy/config/initializers/mime_types.rb
924
- - test/dummy/config/initializers/cookies_serializer.rb
925
- - test/dummy/config/initializers/0_load_development_secrets.rb
926
- - test/dummy/config/initializers/assets.rb
927
- - test/dummy/config/initializers/wrap_parameters.rb
928
- - test/dummy/config/initializers/inflections.rb
929
- - test/dummy/config/environment.rb
930
- - test/dummy/config/routes.rb
931
- - test/dummy/config/database.postgresql.yml
932
- - test/dummy/config/environments/test.rb
933
- - test/dummy/config/environments/development.rb
934
- - test/dummy/config/environments/production.rb
935
- - test/controllers/webhooks_controller_test.rb
936
- - test/controllers/rollbacks_controller_test.rb
904
+ - test/controllers/release_statuses_controller_test.rb
905
+ - test/controllers/status_controller_test.rb
937
906
  - test/controllers/github_authentication_controller_test.rb
907
+ - test/controllers/pull_requests_controller_test.rb
908
+ - test/controllers/tasks_controller_test.rb
909
+ - test/controllers/commits_controller_test.rb
938
910
  - test/controllers/merge_status_controller_test.rb
939
- - test/controllers/commit_checks_controller_test.rb
940
- - test/controllers/ccmenu_controller_test.rb
941
- - test/controllers/stacks_controller_test.rb
911
+ - test/controllers/webhooks_controller_test.rb
942
912
  - test/controllers/deploys_controller_test.rb
943
- - test/controllers/api/hooks_controller_test.rb
944
- - test/controllers/api/ccmenu_controller_test.rb
945
- - test/controllers/api/stacks_controller_test.rb
946
- - test/controllers/api/base_controller_test.rb
913
+ - test/controllers/ccmenu_controller_test.rb
947
914
  - test/controllers/api/locks_controller_test.rb
948
- - test/controllers/api/deploys_controller_test.rb
949
- - test/controllers/api/commits_controller_test.rb
915
+ - test/controllers/api/base_controller_test.rb
916
+ - test/controllers/api/outputs_controller_test.rb
950
917
  - test/controllers/api/pull_requests_controller_test.rb
951
918
  - test/controllers/api/tasks_controller_test.rb
952
- - test/controllers/api/outputs_controller_test.rb
953
- - test/controllers/status_controller_test.rb
954
- - test/controllers/commits_controller_test.rb
955
- - test/controllers/release_statuses_controller_test.rb
956
- - test/controllers/pull_requests_controller_test.rb
957
- - test/controllers/tasks_controller_test.rb
958
- - test/unit/command_test.rb
959
- - test/unit/commands_test.rb
960
- - test/unit/deploy_commands_test.rb
961
- - test/unit/shipit_test.rb
962
- - test/unit/rollback_commands_test.rb
919
+ - test/controllers/api/hooks_controller_test.rb
920
+ - test/controllers/api/commits_controller_test.rb
921
+ - test/controllers/api/deploys_controller_test.rb
922
+ - test/controllers/api/ccmenu_controller_test.rb
923
+ - test/controllers/api/stacks_controller_test.rb
924
+ - test/controllers/rollbacks_controller_test.rb
925
+ - test/controllers/commit_checks_controller_test.rb
926
+ - test/controllers/stacks_controller_test.rb
963
927
  - test/unit/csv_serializer_test.rb
964
928
  - test/unit/variable_definition_test.rb
965
- - test/unit/github_url_helper_test.rb
929
+ - test/unit/commands_test.rb
930
+ - test/unit/shipit_test.rb
931
+ - test/unit/command_test.rb
966
932
  - test/unit/environment_variables_test.rb
933
+ - test/unit/github_url_helper_test.rb
967
934
  - test/unit/github_app_test.rb
968
- - test/models/release_statuses_test.rb
969
- - test/models/deploys_test.rb
970
- - test/models/undeployed_commits_test.rb
971
- - test/models/team_test.rb
972
- - test/models/rollbacks_test.rb
973
- - test/models/commit_checks_test.rb
974
- - test/models/github_hook_test.rb
975
- - test/models/task_definitions_test.rb
935
+ - test/unit/deploy_commands_test.rb
936
+ - test/unit/rollback_commands_test.rb
937
+ - test/test_helper.rb
938
+ - test/jobs/refresh_status_job_test.rb
939
+ - test/jobs/chunk_rollup_job_test.rb
940
+ - test/jobs/deliver_hook_job_test.rb
941
+ - test/jobs/emit_event_job_test.rb
942
+ - test/jobs/perform_task_job_test.rb
943
+ - test/jobs/destroy_stack_job_test.rb
944
+ - test/jobs/purge_old_deliveries_job_test.rb
945
+ - test/jobs/github_sync_job_test.rb
946
+ - test/jobs/unique_job_test.rb
947
+ - test/jobs/refresh_github_user_job_test.rb
948
+ - test/jobs/merge_pull_requests_job_test.rb
949
+ - test/jobs/fetch_deployed_revision_job_test.rb
950
+ - test/jobs/fetch_commit_stats_job_test.rb
951
+ - test/jobs/append_delayed_release_status_job_test.rb
952
+ - test/jobs/cache_deploy_spec_job_test.rb
953
+ - test/models/status/missing_test.rb
954
+ - test/models/status/group_test.rb
976
955
  - test/models/tasks_test.rb
977
- - test/models/output_chunk_test.rb
978
- - test/models/commit_deployment_status_test.rb
979
- - test/models/delivery_test.rb
980
- - test/models/users_test.rb
981
- - test/models/commit_deployment_test.rb
956
+ - test/models/github_hook_test.rb
982
957
  - test/models/duration_test.rb
983
- - test/models/api_client_test.rb
958
+ - test/models/output_chunk_test.rb
959
+ - test/models/task_definitions_test.rb
960
+ - test/models/team_test.rb
961
+ - test/models/release_statuses_test.rb
984
962
  - test/models/commits_test.rb
985
- - test/models/status/group_test.rb
986
- - test/models/status/missing_test.rb
963
+ - test/models/commit_deployment_test.rb
987
964
  - test/models/deploy_spec_test.rb
988
- - test/models/stacks_test.rb
989
- - test/models/hook_test.rb
965
+ - test/models/commit_deployment_status_test.rb
966
+ - test/models/api_client_test.rb
990
967
  - test/models/membership_test.rb
968
+ - test/models/undeployed_commits_test.rb
969
+ - test/models/commit_checks_test.rb
970
+ - test/models/delivery_test.rb
991
971
  - test/models/status_test.rb
972
+ - test/models/stacks_test.rb
973
+ - test/models/deploys_test.rb
974
+ - test/models/hook_test.rb
975
+ - test/models/shipit/check_run_test.rb
992
976
  - test/models/pull_request_test.rb
993
- - test/test_command_integration.rb
994
- - test/helpers/hooks_helper.rb
995
- - test/helpers/queries_helper.rb
996
- - test/helpers/json_helper.rb
977
+ - test/models/users_test.rb
978
+ - test/models/rollbacks_test.rb
997
979
  - test/helpers/fixture_aliases_helper.rb
980
+ - test/helpers/queries_helper.rb
981
+ - test/helpers/api_helper.rb
998
982
  - test/helpers/payloads_helper.rb
999
983
  - test/helpers/links_helper.rb
1000
- - test/helpers/api_helper.rb
1001
- - test/jobs/emit_event_job_test.rb
1002
- - test/jobs/unique_job_test.rb
1003
- - test/jobs/merge_pull_requests_job_test.rb
1004
- - test/jobs/append_delayed_release_status_job_test.rb
1005
- - test/jobs/deliver_hook_job_test.rb
1006
- - test/jobs/refresh_status_job_test.rb
1007
- - test/jobs/fetch_deployed_revision_job_test.rb
1008
- - test/jobs/purge_old_deliveries_job_test.rb
1009
- - test/jobs/refresh_github_user_job_test.rb
1010
- - test/jobs/chunk_rollup_job_test.rb
1011
- - test/jobs/fetch_commit_stats_job_test.rb
1012
- - test/jobs/cache_deploy_spec_job_test.rb
1013
- - test/jobs/perform_task_job_test.rb
1014
- - test/jobs/github_sync_job_test.rb
1015
- - test/jobs/destroy_stack_job_test.rb
984
+ - test/helpers/hooks_helper.rb
985
+ - test/helpers/json_helper.rb
986
+ - test/dummy/app/controllers/application_controller.rb
987
+ - test/dummy/app/helpers/application_helper.rb
988
+ - test/dummy/app/views/layouts/application.html.erb
989
+ - test/dummy/app/assets/stylesheets/application.css
990
+ - test/dummy/app/assets/javascripts/application.js
991
+ - test/dummy/bin/bundle
992
+ - test/dummy/bin/rake
993
+ - test/dummy/bin/rails
994
+ - test/dummy/bin/setup
995
+ - test/dummy/config/initializers/filter_parameter_logging.rb
996
+ - test/dummy/config/initializers/wrap_parameters.rb
997
+ - test/dummy/config/initializers/0_load_development_secrets.rb
998
+ - test/dummy/config/initializers/backtrace_silencers.rb
999
+ - test/dummy/config/initializers/cookies_serializer.rb
1000
+ - test/dummy/config/initializers/session_store.rb
1001
+ - test/dummy/config/initializers/assets.rb
1002
+ - test/dummy/config/initializers/mime_types.rb
1003
+ - test/dummy/config/initializers/inflections.rb
1004
+ - test/dummy/config/secrets.yml
1005
+ - test/dummy/config/database.mysql.yml
1006
+ - test/dummy/config/application.rb
1007
+ - test/dummy/config/database.postgresql.yml
1008
+ - test/dummy/config/database.yml
1009
+ - test/dummy/config/environment.rb
1010
+ - test/dummy/config/boot.rb
1011
+ - test/dummy/config/locales/en.yml
1012
+ - test/dummy/config/environments/development.rb
1013
+ - test/dummy/config/environments/test.rb
1014
+ - test/dummy/config/environments/production.rb
1015
+ - test/dummy/config/routes.rb
1016
+ - test/dummy/public/500.html
1017
+ - test/dummy/public/favicon.ico
1018
+ - test/dummy/public/422.html
1019
+ - test/dummy/public/404.html
1020
+ - test/dummy/db/schema.rb
1021
+ - test/dummy/db/seeds.rb
1022
+ - test/dummy/Rakefile
1023
+ - test/dummy/config.ru
1024
+ - test/test_command_integration.rb
1025
+ - test/fixtures/payloads/push_not_master.json
1026
+ - test/fixtures/payloads/check_suite_master.json
1027
+ - test/fixtures/payloads/push_master.json
1028
+ - test/fixtures/payloads/status_master.json
1016
1029
  - test/fixtures/timeout
1017
- - test/fixtures/shipit/release_statuses.yml
1018
- - test/fixtures/shipit/users.yml
1019
- - test/fixtures/shipit/output_chunks.yml
1020
- - test/fixtures/shipit/deliveries.yml
1021
- - test/fixtures/shipit/hooks.yml
1022
- - test/fixtures/shipit/github_hooks.yml
1023
- - test/fixtures/shipit/statuses.yml
1024
1030
  - test/fixtures/shipit/memberships.yml
1025
- - test/fixtures/shipit/teams.yml
1031
+ - test/fixtures/shipit/check_runs.yml
1026
1032
  - test/fixtures/shipit/tasks.yml
1027
- - test/fixtures/shipit/api_clients.yml
1033
+ - test/fixtures/shipit/users.yml
1034
+ - test/fixtures/shipit/statuses.yml
1035
+ - test/fixtures/shipit/deliveries.yml
1028
1036
  - test/fixtures/shipit/stacks.yml
1029
- - test/fixtures/shipit/commits.yml
1030
1037
  - test/fixtures/shipit/pull_requests.yml
1031
- - test/fixtures/shipit/commit_deployments.yml
1038
+ - test/fixtures/shipit/teams.yml
1039
+ - test/fixtures/shipit/github_hooks.yml
1040
+ - test/fixtures/shipit/hooks.yml
1041
+ - test/fixtures/shipit/release_statuses.yml
1032
1042
  - test/fixtures/shipit/commit_deployment_statuses.yml
1033
- - test/fixtures/payloads/status_master.json
1034
- - test/fixtures/payloads/push_master.json
1035
- - test/fixtures/payloads/push_not_master.json
1036
- - test/test_helper.rb
1043
+ - test/fixtures/shipit/commits.yml
1044
+ - test/fixtures/shipit/commit_deployments.yml
1045
+ - test/fixtures/shipit/api_clients.yml
1046
+ - test/fixtures/shipit/output_chunks.yml