Changelog Digest for Fri, Apr 24

Apr. 24th, 2015 03:01 am
kareila: "PERL!" (perl)
[personal profile] kareila posting in [community profile] changelog_digest

[dw-free]

f3f8937: Issue #1327: fix some undefined variable warnings in LJ::Web
Prevent warnings for undefined variables from showing up in server logs.
55500b5: Issue #1323: break LJ/User.pm into submodules
Move user methods and functions into several submodules for easier maintenance.
9fdeba5: Issue #1323: break LJ/User.pm into submodules
Prevent warnings for undefined variables from showing up in server logs.
bdb9f2a: Issue #1350: Fix some tests
Add t/config-test-private.pl to the skip list in use-strict.t.
2c26fbc: Issue #1350: Fix some tests
Update user domain tests in t/create-url.t for new SSL behavior.
012062d: Issue #1220: t/post.t is broken
Skip default moodtheme check if we haven't defined one in the test config.
c39b3b3: Issue #1220: t/post.t is broken
Update expected values for security group labels.
60cfe8e: Issue #1220: t/post.t is broken
Update _form_to_backend calls to use DW::FormErrors.
949606e: Issue #1220: t/post.t is broken
Add 'sticky_entry' to list of expected entry attributes.
3b07abe: Issue #1220: t/post.t is broken
Don't test for removed altlogin functionality.
68bcbce: Issue #1349: fix issues with test config
Fix various minor issues and warnings related to the new test environment.
2302f3b: Issue #1345: "Insert" button to insert image on RTE no longer exists
Restore initialization of the SiteConfig variable in LJ::Web::rte_js_vars.
b73240d: Issue #1352: Fix more tests
Fix failing tests in formerrors.t (return values changed).
1f9ab63: Issue #1352: Fix more tests
Fix failing test in console-priv.t (error message changed).
aa2eaf6: Issue #1219: t/atom-post.t is broken
Fix atom-post.t by adding $LJ::ONLY_USER_VHOSTS = 1 to test config.
ddb5269: Issue #1340: convert-to-points system does not distinguish between "hasn't been 30 days since last conversion" and "not enough time to convert"
Print correct error message when 'can_refund' is false.
2abb5f4: Issue #1340: convert-to-points system does not distinguish between "hasn't been 30 days since last conversion" and "not enough time to convert"
Add refund rates for paid accounts to etc/config.pl.
3246829: Issue #1340: convert-to-points system does not distinguish between "hasn't been 30 days since last conversion" and "not enough time to convert"
Print the date after which the paid time may be converted to points again.
d89ec42: Issue #1340: convert-to-points system does not distinguish between "hasn't been 30 days since last conversion" and "not enough time to convert"
Tweak wording of error message for consistency with phrasing elsewhere.
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: ddb5269fb815b3f6848c7843bb804e98a841cf19
https://github.com/dreamwidth/dw-free/commit/ddb5269fb815b3f6848c7843bb804e98a841cf19
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-15 (Wed, 15 Apr 2015)

Changed paths:
M views/shop/refundtopoints.tt

Log Message:
-----------
[#1340] print correct error message when can_refund is false

The clauses for "NOT points" and "NOT can_refund" were being tested out of order
and needed to be swapped. Now the more specific error condition executes first.

Fixes #1340.


Commit: 2abb5f49b015f9828821148c56c414b8de7c60a4
https://github.com/dreamwidth/dw-free/commit/2abb5f49b015f9828821148c56c414b8de7c60a4
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-15 (Wed, 15 Apr 2015)

Changed paths:
M etc/config.pl

Log Message:
-----------
[#1340] default config does not contain refund rate for paid accounts

I had trouble testing the previous commit because the config values for _refund_points
were never committed anywhere. Without that information, it prints an unhelpful error
message: "Sorry, your account type is not eligible for a points conversion."

This adds the values we set in production: 30 for paid, and 41 for premium paid.


Commit: 324682928fcc9214642cc7f4b356e2d16eb43f4c
https://github.com/dreamwidth/dw-free/commit/324682928fcc9214642cc7f4b356e2d16eb43f4c
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-18 (Sat, 18 Apr 2015)

Changed paths:
M cgi-bin/DW/Controller/Shop.pm
M views/shop/refundtopoints.tt
M views/shop/refundtopoints.tt.text

Log Message:
-----------
[#1340] print the date after which refundtopoints may be used again

In addition to the current error message of "Sorry, you can only refund
paid time once every thirty days," add clarifying text: "You won't be
able to convert paid time to points again until after [[date]]."


Commit: d89ec421ec18323c200aca2f15184041a145bcc6
https://github.com/dreamwidth/dw-free/commit/d89ec421ec18323c200aca2f15184041a145bcc6
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-18 (Sat, 18 Apr 2015)

Changed paths:
M views/shop/refundtopoints.tt.text

Log Message:
-----------
[#1340] tweak wording of toosoon error message

Change "refund" to "convert" for consistency with nextrefund phrasing.

Renaming the translation key is unneeded because the string was never
displayed on the live site.


Commit: 4bbfa2547464beb29847415282b1c8eb05d63417
https://github.com/dreamwidth/dw-free/commit/4bbfa2547464beb29847415282b1c8eb05d63417
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-22 (Wed, 22 Apr 2015)

Changed paths:
M cgi-bin/DW/Controller/Shop.pm
M etc/config.pl
M views/shop/refundtopoints.tt
M views/shop/refundtopoints.tt.text

Log Message:
-----------
Merge pull request #1348 from kareila/1340-shop-points

fix refundtopoints error message for case where use attempted twice within 30 days


Compare: https://github.com/dreamwidth/dw-free/compare/97d4cce60e09...4bbfa2547464
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: b73240d152f6263a768234ff1051bfdfb3540288
https://github.com/dreamwidth/dw-free/commit/b73240d152f6263a768234ff1051bfdfb3540288
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-18 (Sat, 18 Apr 2015)

Changed paths:
M t/formerrors.t

Log Message:
-----------
Fix failing tests in formerrors.t

Message behavior has changed. Before, we expected an empty string when given
a bogus ml key; now it seems to print the "missing string" error instead.


Commit: 1f9ab63a4b2d9942077c48853396d2d5704c37c3
https://github.com/dreamwidth/dw-free/commit/1f9ab63a4b2d9942077c48853396d2d5704c37c3
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-18 (Sat, 18 Apr 2015)

Changed paths:
M t/console-priv.t

Log Message:
-----------
Fix failing test in console-priv.t

# Failed test at t/console-priv.t line 39.
# got: 'error: You are not permitted to grant admin:*'
# expected: 'error: You are not authorized to run this command.'
# Looks like you failed 1 test of 24.

Update expected error to match the actual error.


Commit: aa2eaf69675dfec3ca5a0c968d3d2381b199f7f4
https://github.com/dreamwidth/dw-free/commit/aa2eaf69675dfec3ca5a0c968d3d2381b199f7f4
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-18 (Sat, 18 Apr 2015)

Changed paths:
M t/config-test.pl

Log Message:
-----------
[#1219] atom-post.t breaks unless $LJ::ONLY_USER_VHOSTS is true.

Add this directive to t/config-test.pl.

Fixes #1219.


Commit: 97d4cce60e0970af59be11ac1e5539ec6c0eef56
https://github.com/dreamwidth/dw-free/commit/97d4cce60e0970af59be11ac1e5539ec6c0eef56
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-22 (Wed, 22 Apr 2015)

Changed paths:
M t/config-test.pl
M t/console-priv.t
M t/formerrors.t

Log Message:
-----------
Merge pull request #1352 from kareila/fix-tests

Fix more tests


Compare: https://github.com/dreamwidth/dw-free/compare/5fae46be2bdf...97d4cce60e09
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: 2302f3bb4b7510dee828d84d639a77a64982f55e
https://github.com/dreamwidth/dw-free/commit/2302f3bb4b7510dee828d84d639a77a64982f55e
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-15 (Wed, 15 Apr 2015)

Changed paths:
M cgi-bin/LJ/Web.pm

Log Message:
-----------
[#1345] restore missing button on dialog to insert image (RTE)

Restores initialization of the SiteConfig variable, which is used by fck_image.js.

Fixes #1345.


Commit: 5fae46be2bdf72aba718cb704e5b93b7f1384536
https://github.com/dreamwidth/dw-free/commit/5fae46be2bdf72aba718cb704e5b93b7f1384536
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M cgi-bin/LJ/Web.pm

Log Message:
-----------
Merge pull request #1347 from kareila/1345-rte

[#1345] restore missing button on dialog to insert image (RTE)


Compare: https://github.com/dreamwidth/dw-free/compare/68bcbce23f77...5fae46be2bdf
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: 258f15261706a96f9c057de53cfb9db4f97bc586
https://github.com/dreamwidth/dw-free/commit/258f15261706a96f9c057de53cfb9db4f97bc586
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M cgi-bin/LJ/User/Account.pm

Log Message:
-----------
In LJ::User->create_community, don't call $u->set_default_style in test environment.

This fixes a test-config related warning that printed during multiple tests, including t/content-filters.t:

"Can't call method "is_custom" on an undefined value at dw/cgi-bin/LJ/Customize.pm line 56."

The reason this was warning is because test environments don't set up styles.


Commit: c4c231b5fcca5304450af92439dcccf42e3f1ec7
https://github.com/dreamwidth/dw-free/commit/c4c231b5fcca5304450af92439dcccf42e3f1ec7
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/config-test.pl

Log Message:
-----------
Add $IS_DEV_SERVER = 1 to t/config-test.pl

This makes sure that t/dev-setup.t isn't skipped by default. In most cases this is not desired behavior.


Commit: bb834dcec7a1e417dd661acf558c7f53199ae726
https://github.com/dreamwidth/dw-free/commit/bb834dcec7a1e417dd661acf558c7f53199ae726
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/config-test.pl

Log Message:
-----------
Configure $LJ::USER_DOMAIN in config-test.pl

This avoids the following warning in t/aliases.t:

"Use of uninitialized value $LJ::USER_DOMAIN in concatenation (.) or string at t/aliases.t line 36."


Commit: 1d1e5f0148d864cd0f33abc4dccb45a5eb7d784d
https://github.com/dreamwidth/dw-free/commit/1d1e5f0148d864cd0f33abc4dccb45a5eb7d784d
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/config-test-private.pl

Log Message:
-----------
Add true statement and newline to end of t/config-test-private.pl

This is standard practice.


Commit: 68bcbce23f771afbba00e9a8c21220309e1eebfa
https://github.com/dreamwidth/dw-free/commit/68bcbce23f771afbba00e9a8c21220309e1eebfa
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M cgi-bin/LJ/User/Account.pm
M t/config-test-private.pl
M t/config-test.pl

Log Message:
-----------
Merge pull request #1349 from kareila/test-config

fix issues with test config


Compare: https://github.com/dreamwidth/dw-free/compare/f83bb97990b6...68bcbce23f77
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: 3b07abe4adaf2ec53d344aa4729b3edda0681f1e
https://github.com/dreamwidth/dw-free/commit/3b07abe4adaf2ec53d344aa4729b3edda0681f1e
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
[#1220] t/post.t: don't test for removed altlogin functionality

We no longer allow remote users to post to an alternate personal account while
logged in, so now the tests for that functionality are failing. Since this is
deliberate, remove the relevant tests.

Fixes #1220.


Commit: f83bb97990b67390cc9415a2c4b414b43c275ef3
https://github.com/dreamwidth/dw-free/commit/f83bb97990b67390cc9415a2c4b414b43c275ef3
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
Merge pull request #1351 from kareila/fix-tests

[#1220] t/post.t: don't test for removed altlogin functionality


Compare: https://github.com/dreamwidth/dw-free/compare/a8e582ccfe86...f83bb97990b6
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: bdb9f2a2fdd075d6ea339a5eeeaf5d7a707db02d
https://github.com/dreamwidth/dw-free/commit/bdb9f2a2fdd075d6ea339a5eeeaf5d7a707db02d
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/use-strict.t

Log Message:
-----------
Add t/config-test-private.pl to the skip list in use-strict.t.

Avoid failed test in use-strict.t for t/config-test-private.pl - config-test.pl was already skipped.


Commit: 2c26fbc18f41224a25df03197f1f94eadaa9fe96
https://github.com/dreamwidth/dw-free/commit/2c26fbc18f41224a25df03197f1f94eadaa9fe96
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/create-url.t

Log Message:
-----------
Update user domain tests in t/create-url.t

# Failed test 'invalid ssl'
# at t/create-url.t line 314.
# got: '1'
# expected: '0'
# Looks like you failed 1 test of 5.

This was the test case with input options: ssl unspecified, host => "foo.example.com"

I assume that the behavior changed when we enabled HTTPS for user domains.

For better coverage, I made the tests for foo.example.com the same as the preceding tests
for www.example.com, which means there are now four tests instead of two:

- https, input ssl unspecified, output ssl = 1
- https, input ssl = 1, output ssl = 1
- https, input ssl = 0, output ssl = 0
- http, input ssl = 1, output ssl = 1

With this configuration the tests all pass.


Commit: 012062dc534b007647faf870f8770930e6e3084c
https://github.com/dreamwidth/dw-free/commit/012062dc534b007647faf870f8770930e6e3084c
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
[#1220] t/post.t: skip default moodtheme check if we haven't defined one

Use of uninitialized value in numeric eq (==) at t/post.t line 129.
# Failed test 'Default mood theme.'
# at t/post.t line 129.

There is no %USER_INIT hash in config-test.pl, so we should skip the relevant test in that case.


Commit: c39b3b3ae56811c96683e60b74ff47c37c6efc21
https://github.com/dreamwidth/dw-free/commit/c39b3b3ae56811c96683e60b74ff47c37c6efc21
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
[#1220] t/post.t: update expected values for security group labels

One example of many:

# Failed test 'Public security'
# at t/post.t line 171.
# got: '.select.security.public.label'
# expected: 'Everyone (Public)'

I just updated these to match the current output.


Commit: 60cfe8e90ae487c24848070e112d82d12c74ce47
https://github.com/dreamwidth/dw-free/commit/60cfe8e90ae487c24848070e112d82d12c74ce47
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
[#1220] t/post.t: updated calling convention for _form_to_backend function

One example of many:

Odd number of elements in hash assignment at t/post.t line 329.
# Failed test 'no errors'
# at t/post.t line 342.
# Structures begin differing at:
# $got->{1} = undef
# $expected->{1} = Does not exist

Looks like DW::Controller::Entry::_form_to_backend used to return an error hash, and now it
operates on a DW::FormErrors object passed to the function.


Commit: 949606ea68d54feeb57658697ecce06497fa9922
https://github.com/dreamwidth/dw-free/commit/949606ea68d54feeb57658697ecce06497fa9922
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-04-17 (Fri, 17 Apr 2015)

Changed paths:
M t/post.t

Log Message:
-----------
[#1220] t/post.t: add 'sticky_entry' to list of expected entry attributes

One example of many:

# Failed test 'decoded entry form with metadata'
# at t/post.t line 474.
# Structures begin differing at:
# $got->{sticky_entry} = undef
# $expected->{sticky_entry} = Does not exist

Adding a sticky_entry key to the reference data fixes the failures.


Commit: a8e582ccfe867d1ea79252a8c5df392a5989f665
https://github.com/dreamwidth/dw-free/commit/a8e582ccfe867d1ea79252a8c5df392a5989f665
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-16 (Thu, 16 Apr 2015)

Changed paths:
M t/create-url.t
M t/post.t
M t/use-strict.t

Log Message:
-----------
Merge pull request #1350 from kareila/fix-tests

Fix some tests


Compare: https://github.com/dreamwidth/dw-free/compare/f0a56c07dd6b...a8e582ccfe86
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: 55500b59294a0f187e7bdc9a300651141dda5abb
https://github.com/dreamwidth/dw-free/commit/55500b59294a0f187e7bdc9a300651141dda5abb
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-03-28 (Sat, 28 Mar 2015)

Changed paths:
M cgi-bin/LJ/User.pm
A cgi-bin/LJ/User/Account.pm
A cgi-bin/LJ/User/Administration.pm
A cgi-bin/LJ/User/Age.pm
A cgi-bin/LJ/User/Data.pm
A cgi-bin/LJ/User/Display.pm
A cgi-bin/LJ/User/Icons.pm
A cgi-bin/LJ/User/Journal.pm
A cgi-bin/LJ/User/Login.pm
A cgi-bin/LJ/User/Message.pm
A cgi-bin/LJ/User/Permissions.pm
A cgi-bin/LJ/User/Styles.pm

Log Message:
-----------
[#1323] move user methods and functions into submodules


Commit: 9fdeba55a02d26a2bdac671dfc943ce58f9681f8
https://github.com/dreamwidth/dw-free/commit/9fdeba55a02d26a2bdac671dfc943ce58f9681f8
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-03-28 (Sat, 28 Mar 2015)

Changed paths:
M cgi-bin/LJ/S2.pm
M cgi-bin/LJ/User/Account.pm
M cgi-bin/LJ/User/Administration.pm
M cgi-bin/LJ/User/Age.pm
M cgi-bin/LJ/User/Data.pm
M cgi-bin/LJ/User/Display.pm
M cgi-bin/LJ/User/Icons.pm
M cgi-bin/LJ/User/Journal.pm
M cgi-bin/LJ/User/Login.pm
M cgi-bin/LJ/User/Message.pm
M cgi-bin/LJ/User/Permissions.pm
M cgi-bin/LJ/User/Styles.pm

Log Message:
-----------
[#1323] remute uninitialized warnings in submodules

LJ/User.pm had defined "no warnings 'uninitialized'" and the submodules did not inherit that.

This should also fix the warnings that were immediately logged when testing.
Mostly in LJ::User but also a couple in LJ::S2.


Commit: f0a56c07dd6b45dd8a8441eae8ffeb7827ee7cb6
https://github.com/dreamwidth/dw-free/commit/f0a56c07dd6b45dd8a8441eae8ffeb7827ee7cb6
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-14 (Tue, 14 Apr 2015)

Changed paths:
M cgi-bin/LJ/S2.pm
M cgi-bin/LJ/User.pm
A cgi-bin/LJ/User/Account.pm
A cgi-bin/LJ/User/Administration.pm
A cgi-bin/LJ/User/Age.pm
A cgi-bin/LJ/User/Data.pm
A cgi-bin/LJ/User/Display.pm
A cgi-bin/LJ/User/Icons.pm
A cgi-bin/LJ/User/Journal.pm
A cgi-bin/LJ/User/Login.pm
A cgi-bin/LJ/User/Message.pm
A cgi-bin/LJ/User/Permissions.pm
A cgi-bin/LJ/User/Styles.pm

Log Message:
-----------
Merge pull request #1326 from kareila/1323-usersplit

move user methods and functions into submodules


Compare: https://github.com/dreamwidth/dw-free/compare/9c2f3a244da9...f0a56c07dd6b
github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
[personal profile] github posting in [site community profile] changelog
Branch: refs/heads/develop
Home: https://github.com/dreamwidth/dw-free
Commit: f3f8937fbf35ef8abcaa8661e15eec72a803d505
https://github.com/dreamwidth/dw-free/commit/f3f8937fbf35ef8abcaa8661e15eec72a803d505
Author: Kareila <kareila@dreamwidth.org>
Date: 2015-03-28 (Sat, 28 Mar 2015)

Changed paths:
M cgi-bin/LJ/Web.pm

Log Message:
-----------
fix some undefined variable warnings in LJ::Web


Commit: 9c2f3a244da9136ebea25e14b2ae44aed583cc69
https://github.com/dreamwidth/dw-free/commit/9c2f3a244da9136ebea25e14b2ae44aed583cc69
Author: Afuna <afuna@users.noreply.github.com>
Date: 2015-04-14 (Tue, 14 Apr 2015)

Changed paths:
M cgi-bin/LJ/Web.pm

Log Message:
-----------
Merge pull request #1327 from kareila/cleanup-2015q1

fix some undefined variable warnings in LJ::Web


Compare: https://github.com/dreamwidth/dw-free/compare/a228da86199f...9c2f3a244da9
Page generated Apr. 25th, 2015 10:53 am
Powered by Dreamwidth Studios