Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for UTF-8 input and output #10

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

@jkeenan
Copy link

jkeenan commented Sep 19, 2023

I forked the Metabase-Fact repository, locally cloned, added this repo ('dagolden') as upstream, then fetched this p.r. with:

git fetch upstream pull/10/head:hakonhagland-utf_support-10

... and checked out the hakonhagland-utf_support-10 branch locally.

I then called perl Makefile.PL && make && make test -- I haven't yet bothered with all the Dist-Zilla-related stuff -- and got one test failure:

$ prove -lv t/user/profile.t 
t/user/profile.t .. 
ok 1 - require Metabase::User::Profile;
ok 2 - require Metabase::User::Secret;
ok 3 - create new profile
ok 4 - An object of class 'Metabase::User::Profile' isa 'Metabase::User::Profile'
ok 5 - profile saved to file
ok 6 - Loaded profile file (created with ->create)
ok 7 - An object of class 'Metabase::User::Profile' isa 'Metabase::User::Profile'
ok 8 - Checking URI
ok 9 - Checking GUID
ok 10 - Checking fact 0
ok 11 - Checking fact 1
Undefined subroutine &metabase_profile::decode_utf8 called at /home/jkeenan/gitwork/zzzothers/Metabase-Fact/bin/metabase-profile line 19.
not ok 12 - created named profile file with metabase-profile

#   Failed test 'created named profile file with metabase-profile'
#   at t/user/profile.t line 85.
Undefined subroutine &metabase_profile::decode_utf8 called at /home/jkeenan/gitwork/zzzothers/Metabase-Fact/bin/metabase-profile line 19.
not ok 13 - created default profile file with metabase-profile
#   Failed test 'created default profile file with metabase-profile'
#   at t/user/profile.t line 88.
Can't open metabase_id.json: No such file or directory at t/user/profile.t line 90.
Use of uninitialized value in subroutine entry at t/user/profile.t line 91.
malformed JSON string, neither tag, array, object, number, string or atom, at character offset 0 at t/user/profile.t line 91.
# Tests were run but no plan was declared and done_testing() was not seen.
# Looks like your test exited with 2 just after 13.
Dubious, test returned 2 (wstat 512, 0x200)
Failed 2/13 subtests 

Test Summary Report
-------------------
t/user/profile.t (Wstat: 512 (exited 2) Tests: 13 Failed: 2)
  Failed tests:  12-13
  Non-zero exit status: 2
  Parse errors: No plan found in TAP output
Files=1, Tests=13,  1 wallclock secs ( 0.01 usr  0.00 sys +  0.10 cusr  0.00 csys =  0.11 CPU)
Result: FAIL

@hakonhagland, can you investigate and add tests as needed? We need to demonstrate that your p.r. will do no harm. Thanks.

@jkeenan
Copy link

jkeenan commented Sep 19, 2023

Environment for the above:

$ uname -mrs
Linux 6.2.0-32-generic x86_64

$ perl -v | head -2 | tail -1
This is perl 5, version 38, subversion 0 (v5.38.0) built for x86_64-linux

Forgot to import Encode::decode_utf8
@hakonhagland
Copy link
Author

can you investigate and add tests as needed?

@jkeenan Think I just forgot to import the Encode module, see added commit.

@xdg
Copy link

xdg commented Sep 19, 2023

I'm not actively working on anything related to CPAN testers. I've asked preaction to add me back to the cpan-testers org so I can transfer this and anything else CT related there so others can maintain it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants