<table><tr><td style="">sitter created this revision.<br />Herald added a project: Plasma.<br />Herald added a subscriber: plasma-devel.<br />sitter requested review of this revision.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D19160">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>+ and add a simple unit test so one can refactor without fear of regressing</p>

<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">something :((</pre></div>

<ul class="remarkup-list">
<li class="remarkup-list-item">osrelease now takes an optional filepath as ctor argument to enable dummy data for testing</li>
<li class="remarkup-list-item">instead of exhaustively if-deffing the config keys are now mapped to member variables in a hash and then resolved through that. this makes the mapping a bit more readable but most importantly reduces the syntactic cruft around it so as to make everything easier to copy paste without messing up by not seeing the important elements clearly</li>
<li class="remarkup-list-item">all currently supported values are now under test</li>
</ul>

<p>among the newly supported keys is LOGO which we'll be able to use for<br />
our logo \o/</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R102 KInfoCenter</div></div></div><br /><div><strong>BRANCH</strong><div><div>os-relesae</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D19160">https://phabricator.kde.org/D19160</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>Modules/about-distro/CMakeLists.txt<br />
Modules/about-distro/autotests/CMakeLists.txt<br />
Modules/about-distro/autotests/OSReleaseTest.cpp<br />
Modules/about-distro/autotests/data/os-release<br />
Modules/about-distro/src/OSRelease.cpp<br />
Modules/about-distro/src/OSRelease.h</div></div></div><br /><div><strong>To: </strong>sitter<br /><strong>Cc: </strong>plasma-devel, jraleigh, GB_2, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>