Skip to content

Commit

Permalink
Merge pull request #155 from p-linnane/fix-various-typos
Browse files Browse the repository at this point in the history
various: fix miscellaneous typos
  • Loading branch information
dmendel authored Jan 15, 2024
2 parents 5d4f2ac + dcab9ce commit 75d889e
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion examples/list.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
# end
# end
#
# Notice how we get stuck on attemping to write a declaration for
# Notice how we get stuck on attempting to write a declaration for
# the contents of the list. We can't determine if the list item is
# an atom or list because we haven't read it yet. It appears that
# we can't proceed.
Expand Down
4 changes: 2 additions & 2 deletions lib/bindata/io.rb
Original file line number Diff line number Diff line change
Expand Up @@ -374,12 +374,12 @@ def write(data)
#
# To create a new transform layer, subclass +Transform+.
# Override the public methods +#read+ and +#write+ at a minimum.
# Additionally the hook, +#before_transform+, +#after_read_transfrom+
# Additionally the hook, +#before_transform+, +#after_read_transform+
# and +#after_write_transform+ are available as well.
#
# IMPORTANT! If your transform changes the size of the underlying
# data stream (e.g. compression), then call
# +::transfrom_changes_stream_length!+ in your subclass.
# +::transform_changes_stream_length!+ in your subclass.
class Transform
class << self
# Indicates that this transform changes the length of the
Expand Down
2 changes: 1 addition & 1 deletion lib/bindata/skip.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module BinData
#
# <tt>:length</tt>:: The number of bytes to skip.
# <tt>:to_abs_offset</tt>:: Skips to the given absolute offset.
# <tt>:until_valid</tt>:: Skips untils a given byte pattern is matched.
# <tt>:until_valid</tt>:: Skips until a given byte pattern is matched.
# This parameter contains a type that will raise
# a BinData::ValidityError unless an acceptable byte
# sequence is found. The type is represented by a
Expand Down
2 changes: 1 addition & 1 deletion test/choice_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ class DerivedChoice < BinData::Choice
_(obj.num_bytes).must_equal 2
end

it "overides default parameter" do
it "overrides default parameter" do
obj = DerivedChoice.new(selection: 'b')
_(obj.num_bytes).must_equal 4
end
Expand Down
4 changes: 2 additions & 2 deletions test/io_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ def value
end

describe BinData::IO::Read, "with changing endian" do
it "does not mix different endianess when reading" do
it "does not mix different endianness when reading" do
b1 = 0b0110_1010
b2 = 0b1110_0010
str = [b1, b2].pack("CC")
Expand All @@ -374,7 +374,7 @@ def value
end

describe BinData::IO::Write, "with changing endian" do
it "does not mix different endianess when writing" do
it "does not mix different endianness when writing" do
io = BitWriterHelper.new
io.writebits(0b110, 3, :big)
io.writebits(0b010, 3, :little)
Expand Down
8 changes: 4 additions & 4 deletions test/section_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class BrotliRecord < BinData::Record
end

obj = BrotliRecord.new
data = "highly compressable" * 100
data = "highly compressible" * 100
obj.s.str = data
_(obj.len).must_be :<, (data.length / 10)

Expand All @@ -52,7 +52,7 @@ class LZ4Record < BinData::Record
end

obj = LZ4Record.new
data = "highly compressable" * 100
data = "highly compressible" * 100
obj.s.str = data
_(obj.len).must_be :<, (data.length / 10)

Expand All @@ -75,7 +75,7 @@ class ZlibRecord < BinData::Record
end

obj = ZlibRecord.new
data = "highly compressable" * 100
data = "highly compressible" * 100
obj.s.str = data
_(obj.len).must_be :<, (data.length / 10)

Expand All @@ -99,7 +99,7 @@ class ZstdRecord < BinData::Record
end

obj = ZstdRecord.new
data = "highly compressable" * 100
data = "highly compressible" * 100
obj.s.str = data
_(obj.len).must_be :<, (data.length / 10)

Expand Down

0 comments on commit 75d889e

Please sign in to comment.