1
0
mirror of https://github.com/github/choosealicense.com synced 2024-11-05 19:28:50 +01:00
choosealicense.com/spec/license_bom_spec.rb
2016-01-28 17:19:42 -08:00

17 lines
310 B
Ruby

require 'spec_helper'
describe "license file" do
bom = "\xEF\xBB\xBF".each_byte.to_a
files = Dir["_licenses/*.txt"]
files.each do |fn|
first3 = File.open(fn) {|f| f.read(3)}
it "#{fn} should not have a byte order mark" do
expect(first3.each_byte.to_a).not_to eq(bom)
end
end
end