polytexnic 1.5.3 → 1.5.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7b4b340dbc85f6c307919402cdedc7400e1bfe4d75050c872e8660403ac6a61c
4
- data.tar.gz: ee6e3c37e601780d5007f371e8df92b6015e4991518ad5e5e07f6d74384d56da
3
+ metadata.gz: 02be0dc8872742300cd432b0eab4a14fa040e231307725f5e9f1923b056c48c5
4
+ data.tar.gz: c372d595c3dc937080606c79b730af946b70126f38cbeef6c11d821a35057650
5
5
  SHA512:
6
- metadata.gz: 30862e9956f342f3d2ffc3de7dae859d19e412eea038ad7525557f45902729aedd8b840dd40103b961309b849ff329119cc65adab842243910678216b076e2ae
7
- data.tar.gz: da30fe166d08c580d1b53a2ea3609e45084095f62ec872ffcf96b7b73d8609225df8546cd979041b59a2cb8bf5dbc008444e5c3f1824883b23edd68bedd4b642
6
+ metadata.gz: 2c5ad4b3ef2536f90c946d7ede9462519745c23862a7ede60dd63f3d359a98d2120c1c3b7639af7f955251ce341ba5c6cfa3eec3787d29963c966ad2a365778f
7
+ data.tar.gz: 69fbdec55ef230eaada63c30d3bab8e660089db636ca5498f94849041de9418770163bed971a0a1647372116f1bceface43336e810bd9a5c2bbce69f7f965136
@@ -79,6 +79,10 @@ module Polytexnic
79
79
  doc.gsub!(/(#{not_a_capital})(#{end_of_sentence})(\}+)[ \t]+([^\s])/) do
80
80
  $1 + $2 + $3 + xmlelement('intersentencespace') + ' ' + $4
81
81
  end
82
+ # Case of "foo.] A"
83
+ doc.gsub!(/(#{not_a_capital})(#{end_of_sentence})(\]+)[ \t]+([^\s])/) do
84
+ $1 + $2 + $3 + xmlelement('intersentencespace') + ' ' + $4
85
+ end
82
86
  # Case of "foo.'') A"
83
87
  doc.gsub!(/(#{not_a_capital})(#{end_of_sentence})('+)(\))[ \t]+([^\s])/) do
84
88
  $1 + $2 + $3 + $4 + xmlelement('intersentencespace') + ' ' + $5
@@ -1,3 +1,3 @@
1
1
  module Polytexnic
2
- VERSION = "1.5.3"
2
+ VERSION = "1.5.4"
3
3
  end
@@ -98,6 +98,11 @@ describe 'Polytexnic::Pipeline#to_html' do
98
98
  it { should resemble "#{intsp} Bar" }
99
99
  end
100
100
 
101
+ context "with a sentence ending with a square bracket" do
102
+ let(:polytex) { "[It's foo.] Bar." }
103
+ it { should resemble "#{intsp} Bar" }
104
+ end
105
+
101
106
  context "with a sentence ending with a single quote and a paren" do
102
107
  let(:polytex) { "(It 'isn't.') Is it?"}
103
108
  it { should resemble "(It ’isn’t.’)#{intsp} Is it?" }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: polytexnic
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.3
4
+ version: 1.5.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Hartl
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2018-05-30 00:00:00.000000000 Z
12
+ date: 2018-07-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: nokogiri