bibtex-ruby 4.0.12 → 4.0.13

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of bibtex-ruby might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 193e1afdfe2905c10d18877578fdbfe4ace343f2
4
- data.tar.gz: 52d755738c0cb14eb5436c44697dc254d20aa8a3
3
+ metadata.gz: fb05bf37b0f9e4eadc96d0404d5ebf5ca6c46905
4
+ data.tar.gz: b3812e113a592625e5a64105b3dee8d63edcc69d
5
5
  SHA512:
6
- metadata.gz: 7f6d3f79a8ae3cdb1c7524cb85e8607435c3e4c4828d3e8db3d0afba73a6af86c34c91817fa7b7c106390f12f61361d30a624cb1c44a5eabf9d3ea88c04515cf
7
- data.tar.gz: 090891732f9682fa2f53f81b35f237625fa0d588136f4ea5f9b45e67d9d5d44c3ecd6ad5081a0afccc0b85395384d1adc90fa9442d5a67530ea19de9fa64cd70
6
+ metadata.gz: 85082f87ba838a46906bfca9dbb7f4bc06ecfa08a7aff0dc892c3da904c7914bf240340ce63bb8b5ecb3758a9affe2c279ce20d352e30a33c233494d25fb7f41
7
+ data.tar.gz: c9a396ce76e4f039e32e4d1b0c6f5276e3d2d3f3a6e4f01ccf112c4cf16da438f137a25d2c69027d5a569b5f827584c7d452031ed4d8460bc4b8bd0892cc51fb
@@ -166,14 +166,14 @@ module BibTeX
166
166
  # Value.new('foo').to_s #=> "foo"
167
167
  # Value.new(:foo).to_s #=> "foo"
168
168
  # Value.new('foo').to_s(:quotes => '"') #=> "\"foo\""
169
+ # Value.new(:foo).to_s(:quotes => '"') #=> "foo"
169
170
  # Value.new('foo').to_s(:quotes => ['"','"']) #=> "\"foo\""
170
171
  # Value.new('foo').to_s(:quotes => ['{','}']) #=> "{foo}"
171
172
  # Value.new(:foo, 'bar').to_s #=> "foo # \"bar\""
172
173
  # Value.new('foo', 'bar').to_s #=> "\"foo\" # \"bar\""
173
174
  # Value.new('\"u').to_s(:filter => :latex) #=> "ü"
174
175
  #
175
- # Returns a the Value as a string. @see #value; the only difference is
176
- # that single symbols are returned as String, too.
176
+ # Returns a the Value as a string. @see #value;
177
177
  # If the Value is atomic and the option :quotes is given, the string
178
178
  # will be quoted using the quote symbols specified.
179
179
  #
@@ -181,7 +181,7 @@ module BibTeX
181
181
  # the filter(s) specified.
182
182
  def to_s(options = {})
183
183
  return convert(options.delete(:filter)).to_s(options) if options.has_key?(:filter)
184
- return value.to_s unless options.has_key?(:quotes) && atomic?
184
+ return value.to_s unless options.has_key?(:quotes) && atomic? && !symbol?
185
185
  q = Array(options[:quotes])
186
186
  [q[0], value, q[-1]].compact.join
187
187
  end
@@ -20,7 +20,7 @@ module BibTeX
20
20
  module Version
21
21
  MAJOR = 4
22
22
  MINOR = 0
23
- PATCH = 12
23
+ PATCH = 13
24
24
  BUILD = nil
25
25
 
26
26
  STRING = [MAJOR, MINOR, PATCH, BUILD].compact.join('.').freeze
@@ -178,6 +178,12 @@ module BibTeX
178
178
  end
179
179
  end
180
180
 
181
+ it 'prints parsed months as symbols' do
182
+ @entry.month = :aug
183
+ assert_match(/month = aug/, @entry.content)
184
+ assert_match(/month = aug/, @entry.to_s)
185
+ end
186
+
181
187
  [[:jan,1], [:feb,2], [:sep,9]].each do |m|
182
188
  it 'should convert numbers' do
183
189
  @entry.month = m[1]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bibtex-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.12
4
+ version: 4.0.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sylvester Keil
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-25 00:00:00.000000000 Z
11
+ date: 2015-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: latex-decode
@@ -145,7 +145,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
145
145
  version: '0'
146
146
  requirements: []
147
147
  rubyforge_project:
148
- rubygems_version: 2.4.5
148
+ rubygems_version: 2.4.6
149
149
  signing_key:
150
150
  specification_version: 4
151
151
  summary: A BibTeX parser, converter and API for Ruby.