From d7b89dce26e2e1d9b96de5871e6460f35f5504dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hannes=20K=C3=A4ufler?= Date: Sat, 6 Aug 2022 17:28:41 +0000 Subject: [PATCH] Support and test crystal 1.5.0 Only two minor warnings, would have worked anyway. --- .circleci/config.yml | 8 ++++---- CHANGELOG.md | 4 ++++ Makefile | 2 +- spec/fake_generator.cr | 2 +- src/crytic/generator/in_memory_generator.cr | 4 ++-- 5 files changed, 12 insertions(+), 8 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 458b3d3e..11dc99ed 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,10 +3,10 @@ version: 2 jobs: test-crystal: &test-template docker: - - image: crystallang/crystal:1.4.0 + - image: crystallang/crystal:1.5.0 steps: - checkout - test-crystal-1.4.0: + test-crystal-1.5.0: <<: *test-template steps: - checkout @@ -29,7 +29,7 @@ workflows: version: 2 ci: jobs: - - test-crystal-1.4.0 + - test-crystal-1.5.0 nightly: triggers: - schedule: @@ -38,4 +38,4 @@ workflows: branches: only: master jobs: - - test-crystal-1.4.0 + - test-crystal-1.5.0 diff --git a/CHANGELOG.md b/CHANGELOG.md index 4cbb9054..267a4e97 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] + +- Support for crystal `1.5.0`. Resolves warnings. + ## [8.0.1] - 2022-04-10 - Support for crystal `1.4.0`. Fixed a bug where the `NumberLiteralSignFlip` mutant would apply to unsigned integers diff --git a/Makefile b/Makefile index f217fa81..a2f73eaf 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ SHARDS_BIN ?= $(shell which shards) SHARD_BIN ?= ../../bin -CRYSTAL_VERSION ?= 1.4.0 +CRYSTAL_VERSION ?= 1.5.0 build: bin/crytic bin/crytic: diff --git a/spec/fake_generator.cr b/spec/fake_generator.cr index 696fd6f3..ecdac63e 100644 --- a/spec/fake_generator.cr +++ b/spec/fake_generator.cr @@ -6,7 +6,7 @@ class FakeGenerator < Crytic::Generator::Generator @neutral = FakeMutation.new.as(Crytic::Mutation::Mutation)) end - def mutations_for(source : Array(Crytic::Subject), specs : Array(String)) : Array(Crytic::Generator::MutationSet) + def mutations_for(subject : Array(Crytic::Subject), specs : Array(String)) : Array(Crytic::Generator::MutationSet) [Crytic::Generator::MutationSet.new( neutral: @neutral, mutated: @mutations)] diff --git a/src/crytic/generator/in_memory_generator.cr b/src/crytic/generator/in_memory_generator.cr index fa9aacc8..ee2d929f 100644 --- a/src/crytic/generator/in_memory_generator.cr +++ b/src/crytic/generator/in_memory_generator.cr @@ -17,8 +17,8 @@ module Crytic::Generator ) end - def mutations_for(sources : Array(Subject), specs : Array(String)) : Array(MutationSet) - sources + def mutations_for(subject : Array(Subject), specs : Array(String)) : Array(MutationSet) + subject .map do |src| MutationSet.new( neutral: noop_mutation_for(src, specs),