Conversation
- Create lib/rotpl.rb as main entry point - Move library files to lib/rotpl/ for proper namespacing - Create lib/rotpl/version.rb with version 0.1.0 - Add rotpl.gemspec with gem metadata and dependencies - Update Gemfile to reference gemspec - Update README.md with gem installation instructions - Update require statements in documentation examples - Update spec files to use new structure - Fix license identifier to LGPL-3.0-or-later The library can now be installed as a gem using: gem install rotpl or added to a Gemfile: gem 'rotpl'
Added three new spec files with 58 passing tests: 1. spec/totp_spec.rb (19 tests) - RFC 6238 test vectors validation - Clock skew tolerance tests - Custom code digits (6, 7, 8) - Custom time steps - Current time generation 2. spec/google_authenticator_spec.rb (16 tests) - Base32 secret handling (with spaces, case-insensitive) - Code generation and validation - Two-factor authentication scenarios - Google Authenticator format compatibility 3. spec/integration_spec.rb (23 tests) - Gem loading and module structure - HOTP → TOTP → GoogleAuthenticator inheritance - Real-world 2FA scenarios (setup, login, clock drift) - Edge cases (large times, epoch, zero-padding) - Performance tests (1000 codes < 1 second) All 58 examples pass with 0 failures.
Enhanced README.md with gem-specific information: - Added gem version badge - Added Requirements section (Ruby >= 2.6.0, base32 dependency) - Added 'require' statements to all code examples - Added section on checking gem version - Enhanced Testing section with detailed test coverage info - Added Development section with local installation and release instructions - Updated Contributing section with test requirements - Added notes about base32 being included as a dependency - Added QR code generation hints All examples now show proper gem usage with 'require rotpl'.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.