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

t: Fix indirect syntax #176

Closed
wants to merge 1 commit into from
Closed

t: Fix indirect syntax #176

wants to merge 1 commit into from

Conversation

rwp0
Copy link
Contributor

@rwp0 rwp0 commented Nov 2, 2023

Fix the usage of indirect object syntax
in test files.

The syntax is discouraged here:

https://perldoc.perl.org/perlobj#Indirect-Object-Syntax

Fix the usage of indirect object syntax
in test files.

The syntax is discouraged here:

https://perldoc.perl.org/perlobj#Indirect-Object-Syntax
@rwp0
Copy link
Contributor Author

rwp0 commented Nov 2, 2023

I don't know how to resolve those non-Unicode file cases.
What encoding should I use for those files?
Both Visual Studio and IntelliJ set UTF-8 by default project-wise.

@rwp0 rwp0 marked this pull request as draft November 2, 2023 20:51
dankogai added a commit that referenced this pull request Nov 3, 2023
dankogai added a commit that referenced this pull request Nov 3, 2023
@dankogai
Copy link
Owner

dankogai commented Nov 3, 2023

You can use perl to do that!

perl -i.bak -ple 's/import Config/Config->import()/' t/*.t

I so did in 4bada5c .

I so did and made sure all occurances of import Config is gone with:

grep 'import Config' `awk '{print $1}' MANIFEST`

t/rt.pl was left undone so I manually fixed it :) cef043c

And CI is now happy.

https://github.com/dankogai/p5-encode/actions/runs/6740663118

Thank you for addressing this issue. Though functionally identical your point is still relevant.

Dan the Maintainer Thereof

@dankogai dankogai closed this Nov 3, 2023
@rwp0
Copy link
Contributor Author

rwp0 commented Nov 3, 2023

Thanks @dankogai !

jkeenan pushed a commit to Perl/perl5 that referenced this pull request Nov 10, 2023
$Revision: 3.20 $ $Date: 2023/11/10 01:10:50 $
! t/Aliases.t t/CJKT.t t/Encode.t t/Encoder.t t/Unicode.t t/at-cn.t
  t/at-tw.t t/enc_data.t t/enc_eucjp.t t/enc_module.t t/enc_utf8.t
  t/encoding.t t/fallback.t t/grow.t t/gsm0338.t t/guess.t t/jperl.t
  t/magic.t t/mime-header.t t/mime-name.t t/perlio.t t/rt113164.t
  t/rt65541.t t/rt76824.t t/rt85489.t t/rt86327.t t/truncated_utf8.t
  t/utf8strict.t t/rt.pl
  Fix indirect syntax accordingly to (but not by pulling):
  dankogai/p5-encode#176
! bin/enc2xs
  Pulled: enc2xs: Fix indirect syntax
  dankogai/p5-encode#174
! bin/encguess
  Pulled: encguess: remove duplicate "the"
  dankogai/p5-encode#173
! bin/enc2xs
  Pulled: Fix spelling in comment
  dankogai/p5-encode#171
! t/gsm0338.t
  Pulled: fix gsm0338 test compatibility with perl < 5.8.8
  dankogai/p5-encode#170
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.

2 participants