diff --git a/src/Helper/Title.php b/src/Helper/Title.php
index a5ddbec..90dd042 100644
--- a/src/Helper/Title.php
+++ b/src/Helper/Title.php
@@ -88,6 +88,18 @@ public function setRaw($text)
return $this;
}
+ /**
+ *
+ * Gets the currently set title string without HTML tag
+ *
+ * @return string
+ *
+ */
+ public function get()
+ {
+ return $this->title;
+ }
+
/**
*
* Escapes and appends text to the end of the current
string.
diff --git a/tests/Helper/TitleTest.php b/tests/Helper/TitleTest.php
index f526fd6..e231183 100644
--- a/tests/Helper/TitleTest.php
+++ b/tests/Helper/TitleTest.php
@@ -81,4 +81,17 @@ public function testSetIndent()
$expect = ' This and That' . PHP_EOL;
$this->assertSame($expect, $actual);
}
+
+ public function testGet()
+ {
+ $title = $this->helper;
+ $this->assertInstanceOf('Aura\Html\Helper\Title', $title);
+
+ $title->set('Bar');
+ $title->prepend('Foo ');
+
+ $actual = $title->get();
+ $expect = 'Foo Bar';
+ $this->assertSame($expect, $actual);
+ }
}